While ads are not the main driver of revenue at Apple they did develop a ad service at the same time they implemented the new "privacy" features on iOS.
https://www.wired.com/story/apple-is-an-ad-company-now/
https://www.searchenginejournal.com/apple-ad-network-gives-m...
https://seekingalpha.com/article/4578462-apples-new-strategy...