14 for a cat is old, at least nature-wise. Very few cats in the wild would ever reach this age. A lot of them start getting pretty weird after 12-13. It could be dementia.
The scratching at the door is totally normal though. A cat has to constantly patrol and re-mark its territory to prevent another cat from taking it over. Closing a door to them prevents them from making the rounds and they will go nuts until it is opened again.