White has just pushed c5-c6 and the black king is in check. Not from in front. Pawns capture on the diagonal, so the pawn on c6 attacks b7 and d7 and no other square on the board, and the king happens to be sitting on one of them.
Two ways out, not three
There are three ways out of check: move the king, capture the checking piece, block the line. Against a pawn the third one is off the table. Blocking means putting something between the checker and the king, and there is no square between two squares that touch. A knight check is the same, for the same reason. That is why both are worth more in an attack than the material count suggests. A third of the defence is missing before you start.
You also cannot castle your way out of one, or out of any check: see castling out of check.
A pawn never checks the square in front of it
Put a white pawn on d7 with the black king on d8 and there is no check whatsoever. The king is standing in the pawn’s way, not in its line of fire, and the pawn is stuck. Slide that same king one square to c8 or e8 and he is in check from a pawn that has not moved a muscle. New players get this backwards more often than any other pawn rule, which is why how pawns capture is worth ten minutes on its own.
Two footnotes. A pawn on the a-file or the h-file attacks one square rather than two, so it checks half as often. And a pawn can give check by capturing en passant, which is a thing most players see for the first time in a game they are losing.
The check that turns into a queen
This is the everyday reason pawn checks matter. 1…Kh8 2.f8=Q+ and the pawn that was giving check is now a queen giving check. Putting the king in the way instead does not help: 1…Kf8 2.Ke6 Kg7 3.Ke7 Kg6 4.f8=Q and the pawn arrives anyway, one move later.
A check that costs your opponent a tempo and costs you a pawn move you wanted to make regardless is the cheapest thing in chess. It is part of why advanced pawns turn up in so many tactics. Whether a pawn can finish the job by itself is a separate question with a genuinely interesting answer: can a pawn checkmate.