People started being called after where they lived or their work and these eventually turned into surnames.
Didn't find the answer you were looking for?