Factory can be used to do a variety of in-game events. Factory can be used to both process harvested farm items, as well as to create new items, such as Fertilizer, Fodder, Earthworms, Heloween Chests, Banner Potion, Salad and many more.
You can access the factory by going to the factory tab on the screen. The factory tab is located on the middle top of the page. The image to the right will show exactly where. You will need to press TAB fist to release your mouse pointer, and after that, you can go and click on the Factory tab.
More info about processing (Use/Destroy Items) can be found HERE
More info about creating items can be found HERE