You are able to receive a Coordination Number (samordningsnummer) if you are staying in Sweden for less than a year and a Personal Identification Number (personnummer) if you are staying for longer than one year.
You can find out more about Coordination Numbers and Personal Identity Numbers in the document entitled Population Registration in Sweden produced by Skatteverket, the Swedish Tax Agency. Otherwise, what follows is some brief information.
Note, you must also inform the Swedish Tax Agency when you have completed your studies and plan to leave Sweden: see Moving from Sweden (pdf).
If you are studying for less than 12 months in Sweden, you can get a Coordination Number (samordningsnummer). For you to get this number, an employer or an organisation must apply on your behalf. The Coordination Number is used so that public agencies can identify you even though you are not registered in Sweden.
Personal Identity Number
If your study time in Sweden is for longer than 12 months, you need to register in the Swedish Population Register at the Tax Agency (Skatteverket): there you will receive a Personal Identity Number (personnummer). This number is used in many everyday situations in Sweden and simply makes life easier for you in all sorts of contexts - from making a doctor's appointment to opening a library account.
Both Borlänge and Falun have a Tax Agency office.
Once you have a personnummer, you can get a Swedish ID card, a useful document to have in many everyday situations.
Study in Sweden has more detailed information about this subject.