A lot of beginning players fail to realize that the idea of a stalemate is incredibly important. If in fact the stalemater is given a victory, as opposed to a draw, our entire understanding of chess will have to be stripped and replaced!
Take for example the very simplest endgame - the King and Pawn versus the lone King (K+P vs. K). Assuming the lone King is not able to simply capture the Pawn, the lone King is only (possibly) able to hold the position via a stalemate. For example:
This is of course a very basic example, but I use this to illustrate the point that in many endgames (in fact, perhaps, a vast majority of endgames!) the player hoping to hold must rely on a stalemate tactic.
Moving up slightly in difficulty from the example above, take the King and Queen vs. King and Pawn (K+Q vs. K+P) endgame, where the Pawn is on the 7th rank (one move away from promotion). When can the defender (the player with the Pawn) force a draw, and when can the attacker (the player with the Queen) force a win? Assume for now that defender's King is close to the Pawn, the attacker's King is very far from the defender's Pawn, and the defender cannot promote immediately.
As it turns out, the answer is a bit of shocker - the defender can draw if the Pawn is on a rook or bishop file (a,c,f,h), but not on any other file! If you do not know why this is, I would suggest you to try and figure out why... I'll explain below!
To first illustrate why this is, I will show how the attacker can win when the Pawn is NOT on one of those files. The Queen itself is unable to force a capture of the pawn by herself (e.g. by a series of checks) but she can force the King to move in front of the pawn (under penalty of losing the pawn), giving the attacker's King one-move time to move closer to the Pawn without fear of the Pawn promoting. Then the process repeats. Observe:
Of course there are other variations and probably more efficient ways of converting the win, but there we see the basic winning approach for the attacker: force the defender's king in front of the pawn and move the king closer slowly.
So now what about the case of the rook or bishop pawn? In both of these cases, the defender has an excellent stalemate resource!
And here is the case of the bishop pawn:
So stalemates (and threats of stalemate) save games!
I will now leave you with some more complex examples. The first case involves a K+Q vs. K+R endgames, where the player with the Rook finds a stalemate resource to save the endgame:
And finally, there is a well-known drawing technique for a K+B to hold against a K+R:
So just remember - if you cannot actively hold a position, maybe you should try to squeeze the life out of your pieces so they cannot move!