What is the name of an anime from 80s-90s movie/series in which there is a scene, maybe the end, where a girl (who has an armor) exchanges age with a dying man in a beach, so the man transforms into a baby and the girl grows to a woman?
This is Hi no Tori 2772: Ai no CosmoZone! (AKA Phoenix 2772)
Phoenix 2772 is set in the distant future where the planet Earth is dying from a lack of energy resources and a disheartening political climate sees all human beings produced by computers to live out certain social roles, the colour of the eyes determining the baby's rank, from pilot to politician, etc. Godo is one such child brought up to be a cadet and nursed by the beautiful robot-maid Olga. After noticing his exceptional abilities, Rock, a dictatorial candidate for prime minister, selects Godo to fulfil his agenda and travel into deep space and capture the mystical Phoenix, its blood will manifestly heal the Earth (and selfishly make Rock prime minister). This eventually proves hard for Godo for many reasons, partly because he has a love of all living creatures and he detests his being trained for what appears to be that of a ruthless hunter. He is also to leave his one friend in his adolescence, Olga, to deletion. Most importantly he elopes with Rena, a "daughter of the elite" and bride-to-be of Rock when it is forbidden for his rank to communicate with such a woman.
For his crime, Godo loses his citizenship and is sent to a labour camp in Iceland where mining energy from the Earth's core is being harnessed in a bid to save the world (but adversely causing earthquakes and speeding up the process). While interned and heart-broken over losing Rena, he meets Doctor Saruta, a prison professor who wishes to counsel the young pilot, only to secretly plot with him a plan to escape, search for the Phoenix themselves and save the Earth. Eventually, Godo is saved by Olga and Pincho (a pet creature of Rena that had helped the lost Olga), and they set into space.
Godo and the crew of the ship find it almost impossible to subdue the Phoenix and it changes into many monstrous shapes and sizes, from dragons to tentacular leeches. After learning that Rena is to marry Rock, Godo had become stricken with misery and pushes away Olga's advances when she shows signs of love (and previously jealousy) for Godo. With the crew all killed one-by-one by the Phoenix and the secret of its weakness lost in Saruta's last words the Phoenix finally destroys Olga by burning her to death, and Godo finally surrenders. As he cradles Olga, realizing how selfish he had been towards his only friend in the world, the Phoenix is subdued by the power of love and thus boards the ship in the form of what appears the cross between an angel and a peacock.
Amazed at Godo's love of living creatures, the Phoenix, speaking with a female voice "herself", falls in love with Godo and grants his wish of reviving Olga on the condition he gives her anything she wants of him (not knowing that this involves his carnal love and the Phoenix possessing the body of Olga to obtain this). After being reunited with Olga and given a paradisal planet to live on, Godo still has feelings towards the dying Earth and sets out to return with vegetables and resources, only to be met with Rock (and a now content and promiscuous Rena) and is arrested. But what follows is a series of earthquakes that level the whole world and bring about final destruction, Rena dying in the advent by trying to escape on Godo's ship and Rock blinded by a lava emission. Godo gives Rock his last rites and he and Olga appear as lone survivors, he then grieves that so much life has been destroyed.
The Phoenix reveals itself to Godo through Olga and requests his wish to lay down his life for the revival of the Earth and its creatures. After the sombre night changes to a starry dawn and after Godo's death the casualties are resurrected. Olga then lays Godo's corpse on the shore and is freed of the Phoenix, only to have her own dead body (beside Godo's) change into a human being. Godo himself is changed into a newborn baby again, and taken by the new human Olga as her son.