Felting is caused by heat and agitation. You want to set your washing machine on the lowest water setting, the highest temperature and the longest agitation possible. Turn on the machine and let it fill with water.
Some people add laundry detergent or baking soda to the water when they felt; I have not seen a difference between using soap and not using soap, other than without soap the process is a little less messy. If you want to use detergent, use about a quarter of the amount you would use to wash your clothes. You can also use a squirt of wool wash, which is what I usually do.
Another point where felters differ is on the issue of bagging your items to be felted. Many people suggest using a zip-top pillowcase to hold items when they are being felted, while others say it isn't necessary unless you are felting very small items that could otherwise be lost in the machine.
I think using a pillowcase is a good idea. If any fuzz is released while your project is felting, it will end up in the bag rather than in your washing machine, where it could cause expensive damage to your machine. Using a case also makes it easier to fish your pieces out of the water.
When the machine is full of water and begins to agitate, drop your bundle in the machine.