Can you retrain a feat into a feat that "must be taken at 1st level", such as Fiendish Heritage or Monstrous Mask?
By RAW, not unless you're still 1st level.
As per the description of the retraining character option, when selecting the new character option after retraining, you must meet all its prerequisites at that time:
When you use retraining to replace some aspect of your character, you must meet all prerequisites, requirements, and considerations for whatever you’re trying to acquire.
A feat that requires you to be at 1st level when it is taken is therefore not a valid option for retraining if you have advanced beyond 1st level.
However, nothing prevents you from using retraining to get rid of a "1st level only" feat, and the rules for retraining specifically identify that they may allow you to change some character feature which is meant to be representative of a permanent part of your background/heritage, as most 1st-level only feats are:
Some of the options listed below involve retraining features of your character that are essentially permanent parts of your heritage, such as a sorcerer’s bloodline. The cost of retraining these things presumably includes magical or alchemical alterations to your body. The GM might rule that these changes are unavailable in the campaign, are only available under rare circumstances, take longer, are temporary, require some sort of quest, or are more expensive than the listed cost.
If I were your GM and I was supporting the use of the retraining rules, I might allow you to retrain a 1st level only feat, but I would almost certainly include extra requirements appropriate to the feat's nature, as the text suggests.
Feats that "must be taken at 1st level" usually represent attributes of the character and are not, per se, things that he "trained" for - unlike most feats. Examples are innate abilities that the character was born with, his ancestral backstory or genetic attributes (an Infernal appearance).
This is what being able to select them only at fist level actually represents - that these are traits which you cannot actually gain by effort or training. So, while retraining one of your feats, you could not possibly start learning "how to change your heritage", so to speak.
That being said, you could always find ways to even change those - like discovering you are and adopted son of a sorcerer - but this goes beyond the actual rules and it is at your DM's discretion.