What causes white pimple on tongue and how can I get rid of it?

Mucocele. Could be a mucocele. Underneath the tongue is a very common place for them and it may be rupturing after a few days looking like an ulcer. Mucoceles are caused by an obstructed or ruptured salivary gland duct, hence clear fluid within. Some mucoceles spontaneously resolve on their own after a short time. Others are chronic and requmucire removal through minimally invasive sx or the use of a laser.
Leave it alone. If it does not resolve in 2-3 weeks see your physician for an evaluation especially if you smoke.