In macOS, the entire display is rendered at 4K no matter what you pick from the resolution box. Most apps have learned to provide 2x-3x “retina” icons so that their bitmap resources look crisp alongside the system UI resources at user-selected “resolutions”.
The Windows UI scaling slider behaves in exactly the same way, though fewer apps include 2x or 3x bitmap resources.