From their own privacy policy they outline what they do:
For research and development purposes, we may use datasets such as those that contain images, voices or other data that could be associated with an identifiable person.
To provide location-based services on Apple products, Apple and our partners and licensees, such as maps data providers, may collect, use, and share precise location data, including the real-time geographic location of your Apple computer or device.
Apple’s websites, online services, interactive applications, email messages, and advertisements may use “cookies” and other technologies such as pixel tags and web beacons.
We also use personal information to help us create, develop, operate, deliver, and improve our products, services, content and advertising
At times Apple may provide third parties with certain personal information to provide or improve our products and services, including to deliver products at your request, or to help Apple market to consumers.
Apple may collect location, IP Address, network information, Bluetooth information, connected devices, accessories, personal demographics, browsing history, browser fingerprint, device fingerprint, search history, app data, usage data, performance, diagnostics, product interaction, transaction information, payment information, purchasing records, contacts, social graph, watch history, listening interests, reading list, call metadata, device information, messaging metadata, email addresses, salary, income, assets, health data, ad interaction, in-app purchases, in-app subscriptions, app downloads, music downloads, movie downloads, TV show downloads, Apple ID, IDFA, Random Unique ID, UUID, IMEI, Hardware serial number, SIM serial number, phone number, telemetry, cookies, Nearby WiFi MAC, Siri request history, Web sign-in, songs played, play and pause times, playlists, engagement and library.
Literally all of this is what Google does. The only thing Apple does differently is hinder 3rd party apps to a greater degree, whereas Google is more permissive. But to be fair, Google has been improving the Privacy features of Android with each version.
Someone made a mistake here. It’s not getting your IP address. An IP address is assigned by the gateway when you’re connected to an access point. An IP address is not an identity. They are always changing and can be shared. This has already been tested and upheld in court.
It’s actually collecting your MAC address. Which is exchanged when your phone or tablet scan nearby WiFi points or Bluetooth devices. However, this can already be defeated. By default iOS and Android both have the option to randomise the MAC address in intervals. Making it extremely difficult to prove anything. This feature exists because the devices real MAC address never changes. It is unique. Alternatively, users can disable WiFi and Bluetooth scanning entirely. However, your device no longer participates in the Find My Devices program by Apple and Google, location does take longer to acquire in some scenarios, and accuracy may take longer to triangulate.