We can sort by code yes but it puts redrawing on the tree.
Why don't you put the code in the name? Example for ring group 802, you will name it 802-Sales Ring Group
So then from the tree you know they are organized, sorted by number/code and you do not have to go in the RG section because you can see the code and the name of each dn respectively.