Metadata is common denominator for all kinds of information that are written in to a file like image files.
In the case of image files some of these information are registered when we take the picture but others you will have to add later. These information are amongst other written in a file that Adobe calls XMP and some time goes with the files as a side car,. Some times these informations (based on the file type) are written in the root of the file. Raw is such written from the manufacturer that little information is to be gotten from them and thus it is difficult to write a program that can embed those metadata informations. They want to keep their algorithm a secret they say. I have only seen one manufacturer have the option of writing basic IPTC data and that was Kodak. Other might be there now with out my knowledge.