Getting checkmated out of nowhere!

It looks like a rather unremarkable mate to me, to be honest. I could see myself being surprised by this one as well, especially in a blitz game, but it would mean I was not paying enough attention.
Your king was in serious danger for at least a few moves before the killing blow was delivered. After 21.Rxh8, your king was stalemated (a stalemated king is a king that cannot move without moving into check). That should be a huge red flag. When your king is stalemated, any check that cannot be blocked or captured will be mate. When I see that queen on c6 and that rook on h8, I see a box drawn around the king with the "rays" that emanate from the queen and the rook (that is, the squares they can move to). That's a death trap. The good news is you should be able to learn to spot such things as you progress.
It would be incredibly difficult to stave off mate in that situation because you're down two rooks, and with that pawn structure, it seems quite unlikely that you'd be able to get a queen. Nonetheless, you could have brought in your queen to try to get your opponent to either trade off queens or withdraw his queen. You'd still be at a huge disadvantage, but maybe your opponent would blunder away a rook and make it easier for you to get a queen or something.
Man, the king was dangerously exposed. That was a big indication already. But yeah you get a 3-4 seconds of freeze-moment when this happens. Don't worry, it'll happen to your opponents too. And when that happens, please relish the moment
i mean 22
Same goes for 21. Bg5+ followed by 22. Qd7#.
@vantangler
Ouch. So close to stalemate (the king cannot move), yet so far (several Black pawns are still able to move before the Black king gets checkmated).

Don't you hate when that happens? this game took a huge left turn on me. Once i realized it wasn't going well, i was trying to force a draw and i got CMed!
https://www.chess.com/daily/game/173146472
Don't you hate when that happens? this game took a huge left turn on me. Once i realized it wasn't going well, i was trying to force a draw and i got CMed!