A Beginner's Scenario:  I castle kingside prior to ever being in check. Then, my son positions his queen and on a subsequent turn, takes out the middle pawn of three (see diagram below), thus exposing my king, and declares "checkmate".  Is this a legal move on his part? Or, may I take out his queen with my king?

![our gameboard][1]

  [1]: https://i.sstatic.net/EsT3x.png