I don't have personal experience with riot shotguns but my layman's understanding is they're very similar to other types of shotguns, just with different dimensions which make them more suitable for close combat and maneuverability. Compared to a longer sporting/hunting shotgun meant to be used outdoors and with no need for a large magazine capacity.
If the riot shotgun was made to fire regular lethal ammunition then I don't see why it wouldn't work. In fact, the shorter barrel length should make it easier to aim at oneself.
What I would NOT ever do is use any "less-lethal" ammunition like beanbags or rubber pellets. I don't actually know if those would work or not but my instinct tells me it's definitely not worth finding out.