If I took electives from another program during my BSc and MSc, how should I list it on my CV?
You shouldn't. This is what your transcripts are for.
If you truly need to point out your data science experience, note briefly when you refer to your education, in the cover/application letter, that this information can be found there.
If you don't think your transcript reflects well enough to refer to, then mentioning the courses without a willingness to back that claim up, will come across as suspicious.