Move points and line follows

I draw a shape with the line tool. From the Top.
Now I what to move some points to z axis. It always move its lines next to it and does not “bend”. How to move a single point in an object and left and right points not moving? (The line)

Thx for help!