Prior to your being convicted, you can entrust the shotgun to a relative, contact your local police agency about surrender procedures, or similarly get it out of your possession. I'm not going to speculate about transfers to somebody else in your home, not knowing anything about your living arrangement, and if you choose to live in a home that includes shotguns and other firearms I suggest discussing the logistics with your lawyer.

Firearms rights in New York may be regained by a pardon, or by your receiving a Certificate of Relief from Disabilities or Certificate of Good Conduct, although the document must specify that firearms rights are restored. See New York Penal Law, Sec. 265.20(5).