That's a good idea, but doesn't work because the army members can be from seperate parts of the hierarchy. Plus there can be several equally-high ranked nobles.
A duke can:
1) Create an army.
2) Assign himself to it.
3) Assign his knight to it.
4) Assign his knight as Marshal.
And thus place himself under the authority of his own vassal. How does that differ from the case of the ruler being in an army?
While I agree that we should hold to the hierarchy whenever possible, there are times when it simply doesn't work for the players.