You've probably seen pictures of cats (and other animals) pressing their heads against a wall before, right? Images like this often circulate on the internet, because they look pretty cute. The animal seems to be sulking, like a child would, or "just can't even" with their silly human owners.
Unfortunately, this behavior, called "head pressing" is far from a joke. If your cat starts doing it, it is in serious distress, and you need to get them help, and fast.