(Not at teacher)
If you just do aerobic exercise at the gym - e.g. running on treadmills etc - then you aren't really going to an aerobics class. You would just say, 'I exercise at the local gym twice a week.'
If, however, you really are going to an aerobics class at your gym then the first is fine, as you said. The second, using 'have', would be better as, "I have aerobics twice a week", i.e. just using 'aerobics' which is the noun of this kind of class/fitness programme.
You could also use the verbs do, attend, go to, and possibly others:
I do aerobics.
I attend aerobics (class).
I go to aerobics (class).
Student or Learner