Prevent iCloud Drive from removing specific folders I'd like to use iCloud Drive to sync my documents + desktop.

However, many times it will remove projects while I'm still working on them (even small ones, like 10MB).

Is there some sort of flag that will tell macOS to sync a folder, but never remove it until I say so?

Mind that I wouldn't like to not sync a certain folder, I'd like to keep macOS from removing it to create purgeable space.
As of macOS Sierra 10.12.4, it is not possible to flag individual folders to stay on your local drive at all times. This is an all-or-nothing toggle.

You may access it under  → System Preferences → iCloud → iCloud Drive Options… There, uncheck Optimize Mac Storage.

This will prevent your files/folders backed by iCloud from being purged automatically from the local storage.