Levels and curves are both powerful tools for tone (re)mapping. Levels is basically a curve with one point between the black and white ends. Both tools are useful to set the image black and white point by adjusting the ends of the curve or dragging the endpoints on the Levels controls.
Curves is a more versatile tool in that you can alter contrast across the tonal range, targeting specific tonal ranges for more contrast (making a segment of a curve steeper) or less contrast (making a segment of the curve flatter). Just remember that if you want to increase contrast in one tonal range, adjacent tonal ranges will receive less contrast as they get flattened. Take for example the typical "S" curve that is used to add contrast to the midtones, mimicking our visual perception of a scene. The middle part of the "S" steepens the curve in the midtones, adding contrast; however, the shadows and highlights get compressed and may lose detail and contrast. Similarly, when working with RGB curves, adding contrast alters color and saturation, another unintended (perhaps) consequence of remapping tones in the image. One can counter this effect by using a Luminosity blend mode or working in Lab and adjusting the L curve.
Curves are also very useful when individual channels are used to manipulate the color in a specific tonal range. If you shoot in shade and your shadows are too blue, you can use the R, G and B channel curves to alter the shadow white balance to a more neutral or warm tone to match the non-shadowed portions of your image, for example. If you are working on an image that has linear data, then curves can be used to adjust individual channel exposure and essentially be used to perform white balance channel scaling (as long as the curve remains a straight line - i.e., dragging the white point left or down).
Curves and Levels are also good dummy adjustment layers for tonal remapping - if you have highlight data that you want to reinforce, you can add a Curves layer with no adjustment to the points and change the blend mode to Multiply to bring back highlights - add a luminosity mask targeting highlights and you now have more uncompressed highlight data. This is more efficient than duplicating a full pixel layer and changing the blend mode and saves file size. Of course once you use the dummy layer to do whatever it is you want, you can also adjust the curve to tweak the result - for example, add contrast to the reinforced highlights - because it is masked with a luminosity mask, you do not need to worry about the deleterious effect it might have on the midtones and shadows. Because it is an adjustment layer, you can alter the opacity to get the amount of the edit just right. And there are the Blend If sliders to play with too.....
Curves, and specifically a Curves adjustment layer, can do a lot of things, from simple additions of contrast and color to complex remapping of tones and colors with different blend modes, masks and blend ifs. Have fun experimenting!