Hi Gisele!
First, the "a" in all of those sentences needs to be "an", because the next word ("English") begins with a vowel sound.
Second, I will answer your question.
"I went to an English class."
-- This means that you went to the place where the class was. Maybe you learned something, and maybe you didn't. Maybe you did some work in the class, maybe you didn't. You were just located at the place where the class was, even if the class was online.
"I had an English class."
-- The idea in this one is a little bit more like you participated or did something in the class. You came to the location, and you also did something or learned something. Sometimes, a teacher will also use this expression to mean that they came to the location of the class and did something (taught).
"I did an English class."
-- This one sounds very strange to me. Probably a native speaker wouldn't say it. If I heard someone say it, I would probably think that it was a teacher talking about teaching a class. However, a teacher normally will say: "I taught an English class."
Lastly, there is another phrase that is also good for you to know.
"I took an English class."
-- This is a common thing that students say to mean that they intentionally chose to have a class, came to the location, and also did and learned some things.
I hope this is helpful for you! Please let me know if you have more questions.
~ Mrs. P. (Kayla)