you have and will read all sorts of things of how buyers justify their expensive purchase, but it's all meaningless, it all boils down to one thing: because the buyers do pay the higher prices. that's all!
so the more important question would be, why are apple customers willing to pay higher prices than customers of other brands? to answer that, you have to dig a little deeper into how the different companies do their marketing, and apple was THE pioneer with revolutional new marketing strategy. they inspire, they are able to spark emotions in the customers. the decision making part of our brain is purely driven buy emotions, even if we delude ourselves that we made a decision out of pure sanity - we didn't. thats not how our brain is wired. so if you are able to spark emotions in your customers you have them on the hook, they become loyal customers because they just feel better using your products. and loyal customers arte pretty much forgiving. customers of other brands often try another brand after bad experiences, loyal apple customers stay at apple. it's fascinating how MUCH the forgive, you can read that in thousand of threads here, no matter how blatantly bad their hardware failed, they buy a new device.
is it better apple engineering? no, just watch channels like that of Luis Rossmann and you will see how badly actually the devices are engineered. the engineers do stupid stuff on the logic boards that make you really scratch your head.
is it a better os? well, no again, it's not better or worse than alternatives.
you just have to get a bigger picture of the topics here. all those users freaking out because of the smallest imperfections they wouldn't even notice on other devices. because the buying decision was such an emotional one, they value the device on a whole another level than they would otherwise. but they don't value them that much because of pure facts of quality or performance, it's just rooted in these emotions.
that's a REALLY fascinating topic, if you are interested I can really recommend reading these two books:
Start With Why - by Simon Simsek and
Hooked - How To Build Habit-Forming Products - by Nir Eyal
They are a fun and easy read and in some ways an eyeopener.