Added bth_put_piece, tests for it

I've based the code for bth_put_piece on code from bth_is_valid_move,
seeing how they are pretty much the exact same thing.