Honestly, its because they make quality products.
I first went with iOS because of the interface. I loved the "skeumorphic" design, it gave the essence of life behind the screen, turning of pages in iBooks blew my mind. And it was soooooo smooth. And their aesthetics of their products design was important to them. If the iPhones were made of plastic, I would've honestly not have been as interested in them as I am now. So from the beginning, I liked everything they were doing.
Another thing I liked about apple was that they always would polish up their products before release (but this seems like more of the past than recent). So other phones would come out with features before apple did, but you could tell those features were half-assed. Apple took its time bringing features of other phones to the market; but when they did, the experience on those were flawless. That is... until the Apple maps era. After that, it seems like they have been trying to rush things out to be competitive in the market, such as the Apple watch and WatchOS1. I think this reflects the main difference between the Jobs and Cook management. I felt Steve was more invested in the quality and completion than Tim is.
Now why do I keep buying them?
1. I am invested in the ecosystem. My family all use iMessage and FaceTime, which is super convenient when they are a whole continent away. I don't see a reason to switch now and force everyone to get some other apps to communicate.
2. The software. Ive been a windows user all of my life up until 3 years ago. OS X's multitouch gestures blew my mind! Ever since, I don't use windows unless I have to. Ive used iOS since the iPad in 2008. I just know it so well inside and out that it doesn't even seem worth trying to learn a whole new system. Plus when I went from my iPhone to an HTC, I just didn't like my phone anymore. It felt more of a hassle trying to do something on that phone than on my iPhone. I don't know if it was the phone itself, or android, but it just wasn't for me.
3. The've still got it with the physical design. Ill admit that I wasn't too fond of the iPhone 6 design, especially because of the camera, but I do prefer it to alternative phones and tablets out there. Macs as well. The one thing I love about the mac is its sleek metal look. I understand that the plastic other manufacturers use is for cost, but I just can't even... I will say though, the surface pros never jumped out as me as anything special, but the surface book actually has a really good design (sans the hinge).
4. They can advertise their beautiful designs. Now at this point I may just be entranced by apple, but they advertise their products in a way where it makes me think "hey, I can use that". Normally Im not one to fall for advertisements, but I fell for one of the Apple Watch videos, then I bought it. Their stores are also a good marketing strategy! I wasn't interested in the new Apple TV until I went into a store and played with one, then I wanted it because of how much of an upgrade it was to the previous model. When I see the amazon fire table, tv, samsung phone, or other ads, I just think "meh". They don't propel me to get one. Even less so, the ads that are actually bashing the devices I use now... I understand their strategy, but their ads aren't making me regret my purchase at all.
I will say though, that my last 3 Apple purchases I did regret getting (iPad Pro, Apple Watch, iPhone 6 plus). I am definitely an Apple fan, because I think they do it all so well. But it seems like Im starting to realize that I don't need all of the gadgets they come out with. Besides, no other company has enticed me enough to switch. The surface book is the closest thing to make me move away from Apple, but it still hasn't succeeded mainly because of the price vs potential resale value. Apple products have an amazing resale value compared to other companies.
EDIT: As someone mentioned above, customer service! The genius bar helped me so many times, free of charge might I add! Ive never had a bad experience with them (except for the waiting time)