Non-EU/EES citizen studying in Sweden for more the 3 months needs a residence permit for studies in Higher Education. You need to apply and have it approved BEFORE entering Sweden: www.migrationsverket.se/English/Private-individuals/Studying-and-researching-in-Sweden/Higher-education/Residence-permit-for-higher-education.html
Non-EU/EES citizen that already has a residence permit for studies from another EU country that is valid for the semester in Sweden only needs to notify the Swedish Migration Agency about the planned stay in Sweden. You need to notify and get a approved response back BEFORE you enter Sweden: www.migrationsverket.se/English/Private-individuals/Studying-and-researching-in-Sweden/Notification-of-planned-mobility-studies.html
Some nationalities also need a visa in order to enter Sweden: www.government.se/government-policy/migration-and-asylum/list-of-foreign-citizens-who-require-visa-for-entry-into-sweden/
Please note that the Swedish Residency Permit and/or notification registration will only be valid until the end of the semester in Stockholm. Depending on your visa situation this might mean that you have to leave Sweden/EU to apply for your permit to next semester in France. Usually this means having to return back to your home country and apply from there.