We usually use the word 'class' when referring to a course in a school, especially when learning with a group of other students.
We usually use 'lesson' when referring to a specific subject, especially one-on-one with a teacher anywhere, not just in a classroom.
"I have an English class today." (singular school course)
"I have English classes today." (plural school courses)
"We are learning about adverbs in my English class." (singular school course)
"I take three English classes each week." (plural - this can mean multiple school courses or the same course multiple times)
"I have an English lesson today." (singular - studying one subject, usually one-on-one with a teacher)
"I have two English lessons today." (plural - studying one subject two times, usually one-on-one with a teacher)
"I am taking lessons for twelve weeks." (plural - studying one or more subjects, usually one-on-one)
"I am going to take violin lessons with Mrs. Robin." (plural - studying one subject, usually one-on-one)
Note: This could also refer to taking the lessons at a school, but if you say you're going to take a lesson with (teacher's name), then it usually refers to a one-on-one lesson.
"Mr. Walter gave me a fun math lesson yesterday." (singular - studying one subject, one-on-one)