Models for coronal mass ejections