If in October 2013 you bought a just released iPhone 5S, you would have had official updates until - apparently - June 2021. Three months ago. Assuming that was really the last security update to iOS 12.
An official Apple device has received one and a half year's worth more updates than two official Google devices put together. The difference between Android support and iOS support is insane.
It's easy to point out that you'd probably need to get your battery fixed at least once to make a 5S last that long, and in 2021 it won't be any fun to use. The people that want to make things last have had the option though, and that's what's important. And with Moore's Law being dead and buried, it's going to be a lot easier to get things to last, too.