The irony is Apple initiated USB-C development and are last to adopt it for their phones. They lead the development of USB-C at the time the EU started calling for all phones to standardise on USB. This whole standardising on one port initiative has been bubbling away for years now. Apple were clearly worried they would be forced to implement a sub-standard connector type and, having thought through the logistical implications, understood they would need to be consistent across their customer base worldwide, so IMO, initiated the USB-C development. One of their key requirements (which is actually quite right) is that the connector can be inserted either way up. Small edge cases, like when you are falling asleep and remember you need to plug in and scramble for the cord with your eyes half open, are actually, because of the annoyance factor, disproportionately important in human factors terms. One thing that can be said for Apple is that they understand this. Lightening, as non standard as it is, is even better in this regard, because you can more easily insert the plug blind to the exact location of the port, so USB-C has always been a slight step down in that regard (but only in that regard).
Of course Apple make a lot of money from the matched charging accessories, but I think they may have moved to USB-C about the time they launched it on the Mac because the whole ecosystem became a bit of a pain. I think the main inhibitor, money aside, was that the EU threat occurred just after they had already forced their customers to complete an expensive transition to using the lightening port. They were still getting a lot of bad press over that and customers were still annoyed. Changing again so soon would have been a problem. If the timing had been better I suspect they would have gone for USB-C across the whole ecosystem from the outset.
Partially I think the initiative was designed to stall the EU - it was a concrete example of Apple’s claim mandating connectors stifles innovation. By initiating a “better” standard and leading it’s adoption by the industry, legislators were given pause to consider if it would have been right to “pick a winner” from the older designs. It succeeded in doing that I think. Partially also it provided a back up uptight for if Apple did have its hand forced - and it did that also. But until now, it’s hand hasn’t been forced, so they stuck with lightening and minting the money from own brand and licensed lightening accessories.