To create armies in a location, it is quite simple. You just have to know the internal name of the unit and follow this:
Code:
create_unit "location/character" "unit internal name" # exp wep arm
So if you wanted to create five fully upgraded Pezhetairoi in Demetrias you would go:
Code:
create_unit "Demetrias" "hellenistic infantry heavy pezhetairoi" 5 9 3 3
To create armies out of nowhere you have to put it in the script since you can't cheat to create new armies. Cheating works the same for the rebels, cheating to add units to an enemy army works fine.
Keep in mind that 'slave' doesn't have ownership for many units. This includes nearly all Roman units and most of the elites. If you give a unit to the rebels or to a faction that does not have the correct DMB etc associations then the game will crash when you try to fight those units on the battlemap. And certain units cannot even be modded to be added to slave/other factions.