Good for Apple. iPhones are great mobiles. I love mine. The hardware is great. With privacy being guarded by iPhones combined with the long software update provided, it is very easy to recommend an iPhone.
If most people realised they never needed to spend more than $600 on a phone the chart might look quite different. The Porsche 911 and an M1 Abrams have their places but a daily commute or trip to the grocery store aint one of em.
People keep Android phones just as long as iPhones. Their software update cycle is a lot faster because most of the core apps are decoupled from the OS. Its not unusual to find phones still getting app updates 6-7 years later (eg Assistant to Gemini) long after the core OS has stalled.
You can of course just buy a $600 iPhone that ticks 99 out of 100 boxes.