Unfortunately for you, because you signed a joint rental agreement, the only way to terminate the rental agreement is for both you and your flatmate to terminate it together.
Once the current rental contract has been terminated, your flatmate and the landlord can agree on a new rental agreement. If you find someone who wants to rent the apartment with your flatmate, they can apply for a contract along with your flatmate.
Of course, there is the chance that your landlord will not agree to a new contract if they have a better tenant lined up or if your flatmate's individual income is not sufficient. Because of this, you should proceed with care and discuss the situation with your landlord in advance.
If your flatmate's income alone is too low to cover the rent (Swiss landlords usually expect your gross income to be 3 times the rent), make sure to find another co-renter who can take your place and make up the deficit.
Best regards from Moneyguru
More on this topic:
Insurance for shared homes
Subletting your rental home: 10 guidelines
8 ways to up your chances of being approved for home rentals in Switzerland
Rental deposit insurance: 11 tips