Draw by stalemate gives a player who is losing a reason to fight on, and adds a whole new threat the winning player needs to look out for, especially in more complex positions. Take this for example.
Question re: draws from a beginner

Stalemate means your king is not in check but he can't move (therefore a draw) unless you have another piece of some sort to move.
Let's say in the position given the computer had an advanced (but not blockaded) pawn and it's Black to move, this would permit a further advance of the pawn so it's not stalemate.
Even though the position for Black is lost, you should have cut him off with Qf7 and promoted the pawn and mate.
I've only been playing for less than the week, so excuse me if I'm missing something simple as I'm sure that I am. I have enjoyed leaning this game so far, but am having trouble grasping the draw by stalemate when your oponent no longer has a legal move. See the image below. I have some understanding of the rule, but to me common sense says that black is dominated and therefore would be losing. Can someone give me some insight on this rule and maybe some strategies to avoid this situation as I have inadvertantly found myself here many times. Thanks!