Doctor said im unable to use certain machinery due to causing swelling in my hand but she didn't put me on medical leave but my employer did. Are they allowed to do this
yes they can. if you can't safely operate a machine they can take you off of it.
In a word - yes. The employer, under certain circumstances and if you are not protected by a union or contract, can terminate you.