Thus, litotes is a literary device used to emphasize a certain trait or idea through understatement or diminishment. The essence of litotes is that we deliberately speak of something as less significant than it actually is to create a special effect. This is the opposite of hyperbole, which exaggerates everything.
When someone says “not bad weather” when the day is actually just perfect. Or “it was a bit difficult” when they meant that it was a very hard task.
Litotes in literature is a way to add depth or irony to the text. For example, when in novels a detective says: “This is not the biggest mystery I have faced,” although the murder was actually very convoluted and hard to solve. Such a device helps convey the emotional state of the characters or create a certain mood in the reader.
In Shakespeare's works, you can find such a litotes: when Hamlet says “I am not much of a poet” to describe his feelings, although his monologues are among the most remarkable examples of poetic mastery. This emphasizes his humility or irony.