Can CDN Identify Whether a User Is on a Desktop or Mobile Device?
No.
You need to distinguish the content for mobile and desktop devices on your origin servers. If a CDN PoP caches the content for mobile devices, when a user accesses that content, the CDN PoP directly serves the content. The same goes for content cached for desktop devices.