Of course do you not really harm anyone if you change it, but as soon as you do it for any form of fraud - and that can range from "re-using" software that was licensed for a specific IMEI to "real criminal" activities as unlocking stolen and blocked handsets by giving them a new IMEI or cloaking your identity for some other criminal reasons.
Let me guess: You got yourself a new phone and you figured out that a lot of software guys got you by the balls as you licensed all games and programs for you old phone - specifically for your old phones IMEI. Yes, it is technically possible with most phones to change the IMEI. But: You're breaking a lot of contracts and you have no idea if any of the programs is possibly checking some other parameters as well - it could be something as banal as screen resolution.
In Germany, there is no special IMEI law - there is no need for it. As soon as you change it for a fraud, you are most likely also breaking § 269 StGB "Fälschung beweiserheblicher Daten". It's basically treated as document forgery to comit a crime. I am pretty sure that there are Swiss laws against the forgery of documents as well.
So: I don't believe it.
Most smartphones are basically portable computers now. IMEI is rarely burned into a ROM but is normally held in NVRAM which normally shouldn't be changed after production, but sometimes the manufacturers get it wrong.
P.S: Next time - read the manual and make a back-up...
There's all kinds of programs floating around the interwebz, alot of which are probably not legal in some countries. If you want to legally distribute it (ie: sell it), then yea, you need some legal experts* advice, if you want to be 100% legit.
(*This doesn't mean asking people on forums )
not quite true, even nokia have been known to send out thousands of phones with the same imei, a lot of cheap no make chinese phones also do not have a unique imei, and mobile phone companies do not rely on imei actually being unique, switzerland also doesn't block imei's