Conventionally every chess problem should have a legal position. Naturally then, an illegal position is a position that cannot be reached by a legal game. For instance, a position in which one side has more than 8 pawns, or has both White and Black Kings in check, is illegal.
A composer of chess problems can have fun creating these...
Diagram - White has just moved a pawn from d7 to d8 and promoted to a knight to checkmate the king, but the move is illegal. Why ?
👍 Read - Who's the Goof ? #5 to discover why
solution on page 8
* Warning - problems like this can do your head in !