I believe that names are inherently important, in that most people having a child will spend a great deal of time and thought on naming. This is true to the extent that anyone saying ‘oh, just use any old name’ when registering a birth would be regarded as eccentric at best, and possibly dangerous. So, names are rarely given casually or thoughtlessly in real life. Somehow, I feel that throwing any old name at a character is a path to weakening the credibility of a story.
Then there’s the reality that some people are rarely called by their birth name as it doesn’t fit. This tells me the idea of names fitting characters matters to many people. I guess that’s one reason we have nicknames. One of my uncles was never referred to by his legal name outside legal contexts (house purchases etc.) Apparently, on first introduction, his grandmother declared his given name to be ill-fitting and called him something different. From that day on, the name his grandmother chose stuck. And it suited him.
As others have said, geography also matters. In many countries (certainly in the UK) there remain clear regional patterns to naming, so a name can hint at someone’s origins. I was always intrigued by a UK TV soap whose writers, it’s said, used to visit local graveyards to source regionally appropriate names. In some legal systems, of course, there are strict rules on what you can and cannot call a child.
Beyond all of that, a name can bring an exotic edge to a character without the need to be sidelined into detailed explanations of their background. The character of Dimitrios, for example, in Eric Ambler’s ‘The Mask of Dimitrios’, has a Greek-Russian name that tells you much of his origins in a single word.
Personally, though, I try not to fret too much about names, preferring to land on them mostly by instinct. So I’ll regularly change a character’s name when developing a story – not great, in that it leads to some painful editing. I often feel like a ghost when I’m writing: floating silently into a scene and trying to work out what’s going on. Part of that is working out what someone’s called. I’m not sure I always get it right. But that’s how it feels.