As World Engineeer explains, your liege has a right to a certain amount of your levies. Whatever remains, are your personal levies, to use as you please.
However, it is still somewhat possible to give your liege or even just a chosen ally control over your personal levies. Gather round, and I'll tell you how.
Raise the amount of levies you wish to waste away, and march them to an allied force. With your army still selected, this is when you will see this little chain button appear as highlighted in my much too dark screenshot below:
As the highlighted tooltip explains, this means your army will start following the allied army around. This is pretty neat in some cases, such as:
a) Due to severe incompetency on behalf of your commanders (and possibly witchcraft), your once glorious army is reduced to a few hobbling peasants. You are in enemy territory far away from home, and all your ships are eaten by termites. An allied force is nearby, but you don't want to tediously move them manually and risk them being torn to shreds because they moved one day too late. You wisely attach them to the allied force, to keep them protected in larger numbers.
b) You finally did something clever, and managed to persuade your liege to claim some lands for you. Everything is going to plan, but your liege just need that final push to win the war. Your hobbling peasants from before won't do much good on their own though, so as before, you attach them to one of the allied armies. Perhaps they can do some good.
Now, the neat thing about this ordeal, is that it is merely a temporary solution, and you are still the man in control. They just follow those other guys around and take part in their battles. When you get sick of that, or you decide it's time for a tactical retreat, you just unattach your guys and run for the hills.
Now, there are also many scenarios, where this is unfavourable. Being a loyal servant isn't always your best bet. Some times, it's better if your liege bleeds a little. A hurt, injured and weak liege is much easier to depose. ;)