Whenever I enter edit mode, these lines supposedly are the edges to edit. But they look to be very squared and detached instead of sticking on the object. Why is this happening?
This is because you are using a surface object, and this is the way surface objects behave. If you want the edges to "stick to the torus" as you say, you will need to convert to mesh (press alt-c and select the second option). You could also simply initially add a mesh torus and use that.