The town of Björnstad (Beartown) is not a real town. But judging by dialects, settings and climates being presented in the series it is rather multiple small towns in northern Sweden.
Based on the novel Beartown from author Fredrik Backman. He is also the author of A man called Ove.