Lighting does a lot of things so what you do with lighting depends on what result you're going after.
Fundamentally, we call it "light", but really we're looking at the light/shadow combination. You can't have "good" light without "good" shadow.
If the lens and the light are in the same spot then the lens wont see any shadow. That results in a flat image. It looses it's dimensionality. The shadows help us notice the dimensionality (the 3D contours) of a surface. So the first thing you usually want to do is get the light to come from the side (and by side I don't mean a 90º angle... I really just mean get it farther away from the lens.) Just getting the light away from the lens will create shadow and give dimensionality to the surface. You'll be able to see textures and contours.
If the light originates from a pinpoint source then that light will create shadows with extremely well-defined edges. If you want to do a shadow puppet show with your hands and fingers you want a pinpoint light source. If you broaden the apparent size of the light source by putting a screen in front of it or reflecting it off a large parabolic umbrella or a number of other light modifiers you can create a light source that seems to be several feet wide. That light would create very soft gentle transitions from light to shadow (which is what most people love). If you were trying to do a shadow puppet show ... such a broad light source would be awful. All your shadow puppets would be soft and blurry because you have a broad "diffuse" light source.
Photographers refer to this as "diffuse" light. I've seen so many products called "diffusers" that snap onto the end of your flash and it looks like frosted plastic. The problem is, they don't make the light source any broader than it already was. This confuses people into thinking that this is "diffuse" light and it's supposed to be better, but the reality is it's just as harsh as when you didn't snap on the little plastic "diffuser". It's no wonder beginners get frustrated and think flash sucks.
You can use light to suggest emotion. How you place the lights can suggest emotions such as despair, loneliness, solitude, peace, happiness, joy, etc. Dimly lit images with mostly blackness and light coming well from the sides and casting long shadows tends to suggest "dark" emotions. Well-lit images with mostly white backgrounds and a glow of light tends to suggest "bright" emotions.
There's a whole new dimension to photography just based on how you light the images.