Think about it. The OS is agnostic to the physical dimensions of a screen. It doesn't matter if pixels are small and highly compressed, or bigger and less densly packed.
The 'size' of the pixel array does not change. Just its presentation in the form of a monitor screen.
UHD = 3840 x 2160, no matter how big or small the actual screen is in cm or inches.
That's also exactly why scaling is a thing: text and even UI elements can become unreadable and unusable if viewed at native resolution if the screen is small. At the same it will be very crisp and sharp. So you can scale up and render everything bigger, but retain the crispness. You're just using more pixels per letter or UI element. It negates the need for subpixel rendering i.e. ClearType et al.