Convert thumbnail ID into image URL

There are two functions you can use for this: wp_get_attachment_url to get the full sized image or wp_get_attachment_thumb_url, which gets the url of the thumbnail of that attachment. Either function takes the attachment id as the sole argument:

$attachment_id= 25;
//Get the full url
$url = wp_get_attachment_url( $attachment_id );
//get the thumbnail
$thumb = wp_get_attachment_thumb_url( $attachment_id );

Not sure how to get this done in your XML file, though, so this is a partial answer, but hopefully it sends you in the right direction.