To use a Fossil Machine, you will need to right click the machine while holding one of the 9 cleaned fossils. You can get these fossils by placing covered fossils inside the Fossil Cleaner. Only fossils that have been cleaned can be placed inside the fossil machine. Once the cleaned fossil is placed inside the machine, the progress bar on the display will begin slowly going up, and the fossil inside will slowly begin to dissolve. Once the fossil has completely dissolved, the Pokémon whose DNA was contained within it will begin growing inside the Fossil Machine Tank. When the display number reaches 100%, the Pokémon in the tank will stop growing and you will need to place a Poké Ball (or any other ball) into the machine by right clicking while holding the ball you want to use. Once you've done this, the Pokémon inside the tank is now yours, and you can right click the machine to retrieve the ball holding your new Pokémon.
The Fossil Machine's texture takes up 9 blocks, with the block it is placed on acting as the center. The 8 blocks surrounding this center block can overlap or pass through any blocks that are also taking up one of those spaces, but this does not affect the performance of the machine.