You won't find any pre-rolled tool for doing this, but it's not too hard once you get the recording bit down. After that, you will need to mix the file with the background music, which can be done simply by adding the raw samples together.
For that part to work, you will either need to decode the background music from whatever compressed format you are using to raw PCM so you can manipulate the samples directly. It's been a long time since I did any iOS development, so I don't know if the iOS SDK is able to do this directly or whether you will need to bundle libffmpeg with your code (or something similar to that). But IIRC, the iPhone does support decoding compressed audio to PCM, but not encoding it (more on that in a second).
Otherwise, you can distribute compressed (as zip, not mp3/aac/ogg/whatever) raw PCM files with your app and unzip them to get the sample data directly.
Once you get the final mixdown, you can stream it directly back through the playback device as raw PCM. If you need to save or export it, you'll need to look again into a decoding/encoding library.
Speaking from experience on this issue, you will probably want to do a bit of basic processing to the vocals before mixing down with the background music. First, you will want to have your background tracks normalized to -3dB (or so) so that the user's voice is audible over the music. Second, you should apply a highpass filter to the vocals to remove all frequencies below 60Hz, as wind or other background noises can be picked up by the iPhone's mic. Finally, you will probably want to apply compression + limiter to the vocal sample to make the vocals a bit easier to hear during quiet stretches.
Unfortunately, the question you asked isn't as simple as "just use function mixdownTracksTogether()", but you can definitely get this working by chaining other tools and functions together. Hope this gets you on the right track!