Crafting - basics
You can start modifying the settlement after you gain access to the workshop mode. You can activate it by walking towards the workshop or by holding the button responsible for changing the view from third person perspective to first person perspective (if you're in the building zone). The interface will change then - you will see a category menu in the lower part of the screen and few pointers in the upper part. Additionally, you will see an aura that will show you the border of the settlement (check the picture below).
The pointers shown in the upper part of the screen show the basic statistics of the settlement which depend on how far developed the location is.
In workshop mode you can not only build new structures (like beds, walls and generators), but also - after pressing the reload building - disassemble the objects that are already existing in the game world. Such structures are surrounded with a frame after you point them with the cursor (as seen on picture below).
You can process almost every part of the game world. Disassembling structures will add resources to the workshop (as seen on picture below).
IMPORTANT Resources created by processing (called junk in the game) are stocked in workshop available in that location. If you haven't created a supply route, you will not have access to all the junk in workshop mode.
Junk collected during free exploration (not in workshop mode) can be stocked in the workshop by pressing a single button (see the picture below).
Every structure that allows crafting can serve as workshop - including Power Armor workshops, a stove or armory table.
Collected resources (junk) can be then used to create various items and structures.
Crafting - finding resources
Having proper resources (junk) is the basis of crafting - without resources you won't create any constructions or items. Resources can be obtained by gathering them or by processing elements of your surroundings.
In Fallout 4 there is a system implemented that allows you to mark resources that you are interested in. In order to do it, select in workshop mode (or while upgrading items) an item to create which you don't have all needed resources. Then press the button assigned to "mark as to search" action. At their names a magnifier icon will appear (as shown on the picture below).
From now on, whenever you find an item containing one of the marked resources, a magnifier icon will also appear at its name (as shown on the picture below).
Crafting - how to turn on the devices that need electricity?
Each device that requires electricity must be connected with a generator (while keeping in mind that it has a limited number of power units). In order to do it, press the jump button after marking the generator and then press it again when you select object which you want to power up (see the picture below). Remember to turn the generator on (you will do it by walking towards it and pressing the action button).
IMPORTANT: There mustn't be any obstacle between the generator and the object that is to be powered.
The power cables can be disconnected by pointing them with the cursor and pressing the button responsible for using Pip-Boy. You must also remember to make sure that the generator is delivering enough power units to the object that it is powering. If it will deliver too little power, the device will not work.
You can connect an adapter to some devices that must be powered up (see the image below).