They always start with "Once upon a time" ...they all end "happily ever after", they are simple stories, mostly the result of fantasy, human and animal protagonists and in the end an implicit or explicit moral that it is: they are the Fables.
Then there are the "real" fairy tales, stories in which each man is the protagonist of his "once upon a time", of his daily battle, of his exciting experiences of life lived in the interweaving with other lives; but it often happens that you don't stop at the point of living "happily ever after", the protagonist continues to live his fairy tale until the end, full of conflicting emotions and experiences ... until he reaches his end.
The end, whether beautiful or ugly par excellence, is never happy.
This is a story like many others, the protagonist "once upon a time", and still is, perhaps he could have lived "happily ever after" but he simply chose to live to the end, until the end.