Freud was wrong about a lot of things because he never studied the theory of evolution, but he was absolutely right about the importance of sexuality for the well-being of people of all ages, including children and the elderly, and recognized that sexual frustration can cause and exacerbate mental illness.
Some relevant quotes:
The behavior of a human being in sexual matters is often a prototype for the whole of his other modes of reaction in life.
No one who has seen a baby sinking back satiated from the breast and falling asleep with flushed cheeks and a blissful smile can escape the reflection that this picture persists as a prototype of the expression of sexual satisfaction in later life.
We know less about the sexual life of little girls than of boys. But we need not feel ashamed of this distinction; after all, the sexual life of adult women is a 'dark continent' for psychology.
You may take it as an instance of male injustice if I assert that envy and jealousy play an even greater part in the mental life of women than of men. It is not that I think these characteristics are absent in men or that I think they have no other roots in women than envy for the penis; but I am inclined to attribute their greater amount in women to this latter influence.
Sexuality is the key to the problem of the psychoneuroses and of the neuroses in general. No one who disdains the key will ever be able to unlock the door.