After putting the flags in wp-content/polylang, you have to refresh the cache.
For whatever reason, Polylang caches the flags. When changing the flags to a custom one, you have to refresh the cache. You can do this by going to the Polylang settings page and press the save button without making any changes.
The last step of Chouby’s answer is obscure, but critical. Supposedly, the flags are cached upon saving the settings. Therefore, when changing flags, you have to save the settings.
Never mind, it magically started working.