Summary:
Certain tiles cannot be entered by certain units. A naval unit can't enter a non-city land tile, for example, and a land unit cannot enter a mountain tile or an ocean tile. If a unit can't enter a tile, you won't be able to order it to move there. Sometimes a move is revealed as illegal during a unit's move. If that is the case, the unit will stop when it discovers the illegality and wait for new orders.