And to finish it up, Macros are basicly a quantity of game commands that can be done by just pressing one button (either ingame or keyboard).
For example, if you have a macro that does these commands:
/sleep
/say ZzZzZzZzZzZz
You can then choose a button, and by pressing it you'd do both things at the same time, which would give the impression you are indeed sleeping.
There are other uses for it, like, for example, tell your party members who are you going to attack next, so everyone attacks it.