You can thank Google for that. From their documentation:
-
Avoid using hardware identifiers. In most use cases, you can avoid using hardware identifiers, such as SSAID (Android ID), without limiting required functionality.Android 10 (API level 29) adds restrictions for non-resettable identifiers, which include both IMEI and serial number. Your app must be a device or profile owner app, have special carrier permissions, or have the
READ_PRIVILEGED_PHONE_STATEprivileged permission in order to access these identifiers.