"Oh, you may not think I'm pretty,
But don't judge on what you see,
I'll eat myself if you can find
A smarter hat than me.
You can keep your bowlers black,
Your top hats sleek and tall,
For I'm the Hogwarts Sorting Hat
And I can cap them all.
There's nothing hidden in your head
The Sorting Hat can't see,
So try me on and I will tell you
Where you ought to be.
(Harry Potter and the Sorcerer’s Stone)
At first I thought, in the highlighted part, ‘black’ is a modifier and changed its place from ‘black bowlers’, for being sound rhythmical. But it seems like ‘keep something + adjective’ construction; and then the comma after sleek and tall has the meaning of but. Entering into the idea, I got curious as to if the phrase ‘keep your bowlers black’ is a traditional saying or the writer’s invention to denote a dandy style. Knowing not British tradition, it leaves me the vague idea. Would you tell me about the sentence and its background?