Yes, garlic can certainly help kill off both microbes and helminths (worms), although a combination herbal blend containing a number of anti-parasite herbs would be better. Certain parasites may respond better to one herb (or antibiotic drug) than to others. Also, parasites can sometimes develop resistance to certain treatments, so treatment rotation between varying herbs is helpful.
When looking at garlic capsules or pills, keep in mind that 600 mg garlic powder equals roughly 1.5-2.5 cloves of raw garlic.
Taken from an MD's website below: "The most powerful natural antibiotic for the gut is, you guessed it, RAW garlic. Oh no you say, not that again! If you can manage to eat 4 to 6 cloves everyday for 4 weeks you will be amazed at the creatures that can be eradicated and expelled from your bowels. Garlic is able to kill bacteria, parasites and yeasts. If you have a large overgrowth, even higher doses may be required. Raw garlic cloves can be grated, chopped very finely or pressed in a garlic press, and then mixed well throughout your cooked food and salads. It tastes nicer with some cold pressed olive oil and apple cider vinegar. Raw onions and leeks also have valuable antibiotic effects in the bowel, and if you cannot tolerate garlic you may find that these things work well for you."