You can do something like this:
private void doClientStuff(final FMLClientSetupEvent event)
{
GameRules.getDefinitions().put("test", new GameRules.ValueDefinition("1", GameRules.ValueType.NUMERICAL_VALUE));
}
There's also a method in GameRules called setOrCreateGameRule, however that doesn't actually seem to create a gamerule, only sets the value, so that probably should only be used when setting the value, not creating the gamerule.
Quick tip: If you're trying to do something that vanilla already does (GameRules, Commands, etc...), look through the code and look at how vanilla does it, or just dig around the code and try to figure out how to solve your problem ?