They certainly don’t see themselves that way. Maybe Lexus or Audi, but not even that.
Those are very niche luxury brands, that sell impractical status products (there isn’t really and equivalent for them in the “computer world”) for the 1% or subset of it. Apple is not that, it’s an upper middle tier mass market brand.
But yes, they certainly don’t care about markets where they can’t be competitive while maintaining their margins