This is a Main Menu command - it should be typed when in the game's main menu (similar to 'developermodeon'), not into the developer console. Typing this into the main menu will enable Iron Forest mode, which makes buildings indestructible. Type ironforest into the main menu again to disable this mode.
The syntax for the ironforest command is as follows:
Search our database of 109 The Forest commands...Yes Please