To fit a 120cm aluminum-framed door in a 126cm gap, fill the 30mm gaps on each side with treated timber or metal packers secured to the brickwork. Attach the door frame to these packers and the wall using masonry screws, focusing on the hinge side first.
Seal any remaining gaps with foam...
Your composite door's locking issue likely stems from a faulty gearbox in the multi-point locking system. Try lubricating, aligning the door, or resetting the gearbox. If that fails, replace the gearbox or call a locksmith.