I read a theory that Dragon was a Princess whose mother taught her to be greedy and the local witch cursed the Princess to become a Dragon for 300 years. So maybe the castle was abandoned because the people in the castle and kingdom either died or moved elsewhere.