Usually cookies are completely harmless and your computer can't get a virus from one. A cookie does not grab your name, address, or anything else from your computer. If you choose to enter your name and email address when you visit a site, then a cookie will allow the people who manage the site to keep track of the information you've entered. But it doesn't send any more information than you choose to give out.
If you want to learn more about cookies, Cookie Central
is an excellent site.