Great question — answering as the UphillTech team:
So from what I have found out is that the chess.com board is a SVG, or not really divs inside of the site. But the main thing is that the pieces are the things in the div. so what you could do is have the engine know the location of the divs, or pieces, and know what they are, so then it recommends pieces, and were to put them.
Full answer by Eli Lohman: https://stackoverflow.stackexchange.com/a/80014495 (CC BY-SA 4.0).
Need it done for your business? UphillTech.