It's tied to an ID3 tag. It's not one you can edit in iTunes, but I think several of the third-party ID3 editors can modify that tag. I'm quite sure they can add the explicit tag to non-iTunes Store music; I think they can also do it with iTunes store music, since you can freely change the ID3 aspects of those files....