Part of that is that Apples software team uses more efficient languages like (eg. Objective-C vs Java). Part of that is that applications on iOS don't have to target a huge variety of screen resolutions (and therefore are frequently loading then downscaling high res textures). Part of that is that RAM doesn't get much cheaper if you buy at Apple-scale - so a RAM bump represents a bigger hit to margins than adding other features.
But all of that comes back to bite when using LLM's, which inherently gobble RAM. And any memory saving techniques used will simply allow a competitor with more RAM to squeeze in an even bigger better smarter model.