Hi there,

I have been playing for about 1.5 years, im progressing alright but I have trouble with keeping my rhythm.

For instance if i try tap my foot and play at the same time, one of them will decide to stop working, or even worse sometimes both of them

This is the same if i try and do differnt tapping rhythms with my each hand.

I was wondering if there were any excersises that could help me improve my noobness and would purchasing a metronome be helpful?

thanks in advance
Absolutely get a metronome. It will be frustrating at first, but take it slow and keep working at it, and you will see a night and day improvement in how tight your playing is over time. Don't stop tapping your foot though - do that in addition to the metronome.
You've gotta practice with a metronome. Also count out loud as you tap your foot. Start with a reasonably slow tempo, 70-80 BPM. Increase gradually as you become more comfortable. "Locking into the beat" takes a little time, but be patient, you'll get it. One of the teachers I had in college used to listen to his metronome alot, (in his car, at night while laying in bed, etc.). He'd practice counting and subdividing the beat at different tempos. By listening, he could tell you what the tempo was (without seeing it), within a couple of beats. His timing was amazing. Obviously, this method is a little extreme, but it worked for him. And don't limit yourself to counting just when you practice. Count along when you listen to music. Good luck, let me know if you need anymore help.