D&D 5e How to “properly” use polymorph?


I’m a new player trying to learn more and how the spells really work besides any game.

I was in a session, and occasionally a player used the "true polymorph" spell on a teammate to make it into a Planetar, and our DM said the spell only changes the player’s body so he would have no weapon (long sword) not even his characteristic as: Angelic Weapons, Divine Awareness, Innate Spellcasting and his Healing Touch. My question is, how to use the spell correctly? Can I use all of your skills and actions, including legendary actions? Can I use everything listed on the monster sheet? And another, if I transform myself permanently, can I level up and progress? From what I understood about the spell you can become a creature and play with everything and only what is described the creature sheet.

Being a new player, I always like to argue about and find out how my and other player’s actions really would work.