Hi there,
This issue might occur if the following conditions are true:
-You use Group Policy Preference (GPP) or logon scripts to map network drives during logon.
-User Account Control (UAC) is enabled.
-The following UAC Group Policy setting is configured to Prompt for credentials:
-User Account Control: Behavior of the elevation prompt for administrators in Admin Approval Mode
-The EnableLinkedConnections registry entry is configured. See the detail to configure the EnableLinkedConnections registry entry.
You can try the workaround from the below article.
Mapped drives are not available from an elevated prompt when UAC is configured to Prompt for credentials
https://learn.microsoft.com/en-us/troubleshoot/windows-client/networking/mapped-drives-not-available-from-elevated-command
--------------------------------------------------------------------------------------------------------------
--If the reply is helpful, please Upvote and Accept it as an answer--