The noun melancholy can be countable or uncountable.
The singular form of melancholies is melancholy.