Note that printer sharing is intended for non-network or non-wireless printers that are usually directly connected to your computer. If your printer is already network, wireless, or AirPrint compatible, you don't need to share it, as it is already shared on your network.
To share your printer on a Mac, first, click on the Apple menu, then click on System Preferences. Next, click on General in the sidebar, and select Sharing on the right side of the window.
Once the Sharing window appears, turn on Printer Sharing, and click on the Info button on the right. Below Printers, choose the printer you want to share.
Now, you can choose who can use the printer. To let everyone use the printer, click the pop-up menu next to Everyone, and select Can Print. If you want to choose specific users who can use the printer, click the Add button at the bottom of the Users list, and select the users you want.
Finally, click Done to save any changes you made. To remove a user, select the name, then click the Remove button. Note that you can't remove Everyone.
For more information, you can refer to this link: https://support.apple.com/guide/mac-help/share-your-printer-on-mac-mchlp2424/mac