Well i dont have guitar so this might be noob question . But how do people record their guitar while a song is playing like this -https://www.youtube.com/watch?v=ukfJ8qbFiuc

Do they remove the guitar part from the song and use their own guitar tune ? It really feels like they are performing guitar port of the song live .
It seems that the original guitar parts are there , and he's just playing over the original track...

There are many ways to get the backing track for a song...

you could use guitar pro (though it won't sound very good)

or use VST instruments in a DAW (would sound better)

but really the best way would be to ask other people to record the other instruments for you....there was a thread somewhere in this site where people made backing tracks on request .... can't find it t the moment , it was called something like "the official UG cover band" or something....

this thread could be useful too :-
guitarbackingtrack.com is the best site with tracks for guitar covers...I use them myself too enjoy