How can a glossy finish be achieve on a wooden desk?
You want a gloss enamel. 

Yes, you can use spray paint with it ... although I'd definitely sand it VERY carefully first with an orbital sander and 120 and 220 sandpaper, wipe down with tackcloth very carefully, prime with an oil based primer, sand again with 220, wipe, prime again, and sand AGAIN with 220 or possibly even a finer grit ... you want to make sure that the surface is absolutely perfect before you even try to paint with a gloss paint. Gloss finishes are the hardest to get a decent finish with. 

Use thin coats of paint and build it up, trying to make it as even as possible. Don't be afraid to go over it with some 220 and then another finer grit of sandpaper if you feel like you've messed it up. Keep in mind that full cure times for enamel is generally 24+ hours and you'll want it to fully cure before you try to sand it, move it, recoat it, etc. 

If you're brave, you can also try rolling it with a foam roller and some penetrol. A pint of gloss enamel shouldn't run you that much, and if you have done the prep right, mix it right, and apply it right you can get just as good a finish as a spray finish... or better if you're not used to finishing surfaces with spray cans or equipment. 

If you go the can-and-roller route, avoid Rustoleum and go with something that is good, like Sherwin. If you go with cans, avoid the "Rustoleum Universal" spray cans, the spray heads on them suck. Just regular "Painter's Touch" or Krylon will work fine.