Hi @Luís Costa,
With the current setup (Exchange on-prem with Hybrid Mode), users are created in AD and then a remote mailbox is created as a shared mailbox for that user.
Do you mean currently you are running the "Enable-RemoteMailbox" PowerShell command with the "-Shared" switch from Exchange on-prem?
To the best of my knowledge, if you want to convert a synced user account to shared mailbox from the portal, agree with the replies above that you may have to assign a license to it first. If your concern is that there are no spare licenses available, you can remove one from a user who doesn't require a license or is not using Office 365 services currently temporally.
Below are some similar links for reference:
- How to: Convert an unlicensed user/mailbox to a Shared Mailbox in Microsoft 365/M365/Microsoft Office 365/O365 easily
- Create a Shared Mailbox from a new Synced User Account
(Please Note: Since the web site is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.)
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.