I have a `geom_histogram` created with `ggplot` and I need to change the legend's title.

I find a lot of links about doing it with `opts` but it is deprecated now. The `theme` command allows to change esthetics, but not the title of the legend itself. 

Which is the way of doing it?