If a player is in check, but can make a move that will put the opponent in checkmate, but it will not remove themselves from being in Check, is that a legal move?  

For example, in the image below, if black plays Rf8, the black king will still be in check, but the white king will be put in checkmate. Is this move legal?  

[![Checkmate while still being in Check][1]][1]


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