The Prophet Muhammad(PBUH) instructed his followers, at the time, to avoid any intoxicating substances -- (paraphrased) "if it intoxicates in a large amount, it is forbidden even in a small amount." For this reason, most observant Muslims avoid alcohol in any form, even small amounts that are sometimes used in cooking.