I always do my pull-ups with my legs stretched out, no matter the height of the bar. But, the thing that bothers me is that I can't manage to keep my legs in a straight line with my upper body during the workout — they almost always move forward when I lift myself and I feel like that is actually helping me do more pull-ups — it feels like my legs are making the exercise easier on my biceps & back muscles. I have also noticed that bending my legs backwards is making the exercise harder than when my legs are straight. Why is it so?
If you're moving your legs forward while pulling yourself up, it's a way to "cheat" a little bit on the movement. You're using the momentum of your legs swinging up to help you pull yourself up.
It's not really a problem, since it'll help you get some more pull ups in, but you should try to keep your legs stationary throughout the movement. (You can keep them up, down, or crossed, but try to keep them steady regardless of where you are during the pull up)
As far as why it feels harder if your legs are kept back, that's likely caused by two things. First, it may have the opposite effect if you're kicking your legs back. Second, by keeping your legs behind you, you're stretching your core and using that during the pull up in addition to your other muscles.
For best practice, try to keep the upper part of your legs (down to your knees) straight with your back, and bend your knees slightly so your feet are behind you. Do not flail/kick your legs and focus on your back/lats/biceps.
Whether your legs are bent, in an 'L' form (to add abs), or straight down, the importance is consistency...so find your comfort zone and stick with it.
Assuming you aren't swinging to get extra momentum and doing those asinine "kipping" pull-ups that seem so popular these days, it's really simple physics.
First, in order to be balanced, the pull-up bar needs to be directly over your center of gravity. Think about a pendulum, it will always come to rest directly under its support. Well, the same thing holds when you do a pull-up. As you do a pull-up, you naturally have to lean back as you pull your head over the bar (otherwise you'll bang your head, not recommended), which brings your center of gravity back. To compensate, your legs will naturally float forward to bring you back into balance. If you fight it and force your legs back, you have to apply an additional torque through your core and arms which will naturally make it harder.
The second reason is that when your feet go forward, your upper body will lean back slightly, putting your lats and traps it a more advantageous position, allowing more of your muscles to be used while pulling you up. Think the difference between a lat pulldown and a seated row; by having a slight lean you are slightly closer to a seated row-type motion.