Start drawing your path as normal and if you want it closed hold down the "Alt" key in windows and that would be the "Options" key on the Mac. What I would say that it should not be drawing single lines. The other thing I would say that the pencil tool is really a free form tool to be used with brushes and sketches try a learn to use the Pen Tool for closed paths as that is where the power of Illustrator is.