They're "small" expenses but if you track out the various things and divide them over the ownership period, they do add up.
E.g. - current house, here 5 years, so far: furnace and A/C, $9k, fence, $14k, landscaping and misc, $2k, tools and supplies, $3k, plumber and window repairs, $2k. So about $6k a year, double my taxes and half my mortgage again. And I haven't even hit the big ones (and didn't count appliances as those were "optional" purchases).
Owning is still a good idea for many, and has benefits, and renting will almost by definition be more overall, but it's not a given. You note the main advantage - stability. If you're on a fixed loan (whether it be 5, 10, 20 or 30 years) your payments are calculable years in advance and you get to pay much with tomorrow dollars, which are almost always worth less than today dollars.
But you do have to want to stay in the area for years.
On the other hand, you have to count the mortgage interest as a cost but not the mortgage principal repayment.
Obviously, this won't hold true for all time-frames, and I'm not even necessarily a fan of thinking of primary residences as investment vehicles, but if you're going to compare it for opportunity cost it's still not necessarily a home run comparison.
One of the biggest benefit of owning is a hedge against housing inflation. Its not a perfect hedge, I do acknowledge. As property values increase my taxes go up, as housing materials increase in cost the cost to repair it goes up. But the amount my taxes will go up in a year is far less than how much I've been seeing rents shoot up.