How to give babies medicine without them spitting it up ?

So im having difficulty giving my son who is 3 months medication,.. he spits it alll up and doesnt even keep it in. Idk what to do