I have small bald spots in the back of my head what treatment can I use to treat that and what causes that?

Alopecia areata. Topical or injections with cortisone in dilute amounts can help resolve this problem within a few visits with a dermatologist. Natural treatments that are safe and effective are not available.
Fungus OR alopecia. If the bald spots show any kind of redness (inflammation) then the likely diagnosis is tinea capitus which requires an anti-fungal presciption pill to cure (topical meds do not work) if the bald spots are just bare skin then the diagnosis could be localized 'alopecia areata'. This condition is thought to be 'auto-immune' a dermatologist may inject cortisone for resolution. Hope you are better.