assigning controls to gaming mouse

just wondering if this is possible I have a 6 button gaming mouse and would like to be able to map the all troops and local troops to my side buttons but it doesn’t work on the controls screen

Did the mouse not come with some sort of custom mapping software exterior to the game? If it did, that should work, but it’s been while since I’ve PC gamed, so maybe this isn’t a thing anymore.