Hello,
This is a Group Policy Set under:
User Configuration -> Administrative Templates -> Windows Components -> File Explorer:
the Policy is called "Remove Map Network Drive and Disconnect Network Drive"
If that policy is enabled it will gray out the option in File Explorer. Set the policy to Disabled or Not configured to fix this.
If this helped resolve the issue please Upvote and Accept this answer.
Thank you and have a great day!