How to make this? (Voxels)

Quite a bit of reference material out there :

http://paulbourke.net/geometry/polygonise/

Sebastian Lagues’s Unity tutorial on Marching Squares may make understanding it easier