When a player cannot make a legal move but is not in check, a stalemate exists. The match has ended in a draw. Neither player wins and neither loses.
In this illustration, a black rook moves from b7 to b3. White is not in check, but cannot legally move either of its pieces. The white bishop at e1 is blocking check by the black rook at f1 and cannot be moved. All four of the hexes within the white king's reach are under threat by either Black's bishop at c4 or rook at b3. This match has ended in stalemate.