So far all I’ve done is go through the Unreal Editor tutorial series (up to maybe #77 now). I would say open the project properties, go to Input and add a new action mapping for left click. Call it “Place block” or whatever.
Then, under your player’s event grid (assuming you have a player set up?), add the “Place block” event trigger. Have it create a static mesh relative to your player’s location.
I imagine the only challenge would be aligning it to a grid, but it could probably be done by getting the coordinate offset relative to the player, getting the world coordinates of that location and rounding it to the nearest ~200 unit interval (or whatever your block size is).