There's an option to write to file, for each library field. This is located under Options -> Library & folders -> Manage Library Fields...
If the info can be written to the files, and this option are selected, it will do so. If the file can not be written to (some types of music and video files for example), MC will create sidecar files in most cases to store the info. I'm not sure about image files. The library always contains the changes as well, of course.