As to the "why buy" question, I don't view it as an investment at all. I know it technically is, but, aside from doing my best to buy a place I'm confident will hold/increase its value, it was an immaterial consideration when I decided to buy.
I like the ability to customize and do whatever I want with the house, and that was a consideration, but for me it came down to three things: Control, location, and a sense of permanence. I figured this all out as a result of renting for a few years after owning.
By control, I mean the ability to oversee everything that happens with the house. When we were in the rental, we had a great landlord, but he was still a landlord. If something broke, we didn't have to pay to fix it, but we also didn't control how it was fixed. That meant everything was "good enough," but not great.
For location, there aren't a lot of rentals in the areas we liked, and the neighborhoods that do have rentals aren't as nice as their primarily-owner-occupied counterparts. After living in a neighborhood with a larger rental population, you can really see the difference from areas that are mostly owner occupied, and the latter is superior in every way.
The clincher for me, though, was the permanence thing, and this was largely psychological. MrsG and I have been somewhat itinerant in our marriage. We've moved something like eight times in the ~13 years we've been married. Now that we have kids and school on the horizon, that much bouncing around just isn't an option. We didn't like where we were renting, and we know we like where we bought, so this was our way of forcing roots to be planted. This is our home, and we need to really build our life here. The house we bought is definitely "forever home" material, but we intentionally bought in an area where there are a lot of upgrade options nearby (e.g. in the same school district), just in case we decide to upgrade again.
Honestly, if I were single, or even a DINK, I'd strongly consider renting in perpetuity, and it was still something I considered at length for our family before we bought again, especially because I was pretty strongly put off of buying again after not having a great experience last time around. But the stuff above was just enough to nudge me toward buying again, especially when combined with 3.xx% interest rates and a market on the upswing.