Instead of giving checkmate, I gave stalemate. Why? I am a beginner, and I have just discovered this annoying stalemate. I got the definition but while playing, I ended up with a stalemate and I don't know why. Could you explain it to me?
[FEN &quot;8/8/4K3/8/6R1/2k5/7R/1R1R4 w - - 0 1&quot;]

I had 4 rooks that were supposed to block the king so he could not move anymore. Isn't this supposed to be checkmate?
No; for checkmate, the king must be in check, i.e. attacked by one of your pieces. This isn't the case in the position you posted, but if you were to move, you'd be able to force mate in two:

[FEN "8/8/4K3/8/6R1/2k5/7R/1R1R4 w - - 0 1"]

1. Rh3+ Kc2 2. Rg2#


Actually, you don't need that many rooks to checkmate. A lone king and rook will be enough; the procedure is explained in this Wikipedia article.