For a simple way to add a search button to your WordPress menu, use the Ivory Search plugin. It provides all sorts of controls, including the “Sliding” option which I selected.
Here’s a great article on adding search, and the options to do so either through a plugin or custom PHP code.