I'm going to ignore the CAS / student visa thing for a moment, and just focus on the course change first.
Universities will typically allow you to switch courses before the course has started if (a) there is space on the course you want to switch to, and (b) if you meet the entry requirements for the new course.
You can obviously check whether you meet the entry requirements for the new course yourself, but you'll need to phone them to establish whether there's still space on the course you're thinking of switching to. (When you make this call, you may as well ask them about their course switch policy and the implications for your CAS and student visa.
Depending on the nature of the course switch, you may need to apply for a new student visa. This will be the case if the new course ends on a date after which your visa is due to expire, or if the new course is not related to the original course. (If it not related, you might not not need a new visa if the new course support a genuine career aspiration and you can write a short statement in support of that.)
It is my understanding that a CAS is issued for a given course, so that would likely need to be reissued.
Are your second thoughts really worth all this hassle? What course switch are you considering? From which course to which course?