Taking lessons is a great idea. It will give you structure and practice to help you gain confidence you aren't making a fool of yourself.
In terms of getting out of your head, recognize that a part of you is frightened and likely needs reassurance. That fear is trying to keep you safe by shutting you down in a freeze response so you don't harm yourself. It doesn't know that you're safe and from its perspective you aren't. Don't gaslight this fearful part. Instead see if you can offer it some gratitude, thank it for its service and see if it might be helped to gain confidence in you that you and your desire to dance can be trusted in a world where people can be cruel.