In theory you could add 5 million factions, only problem holding you back is memory usage, each faction in napoleonic wars has about 10 regiments with about 4 ranks each, thats 40 unique uniforms, 40 textures, 40 normalmaps, 40 specmaps.
Adding a lot of memory usage, if you have too much of that the game will crash on low-spec systems.
Some mods might not have their nations that extensively unique allowing for a lot more nations without using too much memory.