It's very possible! The voice is an instrument like any other, you just need to train yourself to hear pitches.
Transcribing melody by ear isn't too hard if you have the proper tools :). Download a trial of Transcribe! or the free program Audacity, import the track, then take it slowly.
Try to sing the melody, then imagine what you'd play on guitar to match that. Cursory knowledge of music theory and the notes on the fretboard can make this a great deal easier. I'd recommend using musictheory.net and finding a diagram of notes on a guitar to assist.
Hope this helps.
You are more than capable of doing this. Do not get mad, do not be impatient. This is an exercise, you just have to train.