I had some success with volume control of HiFiBerry-OS via fake usb keyboard today, Arduino is connected directly to rpi as a keyboard would be.
I'm using an arduino micro (easy beacause it uses ATmega32U4) with the KY040 rotary encoder (push buttons would also work as an alternative or for extra functions).
I think a 'normal' usb keyboard won't work as the the arrow keys (cursor up/down) don't seem to have any effect on the volume. A multimedia keyboard with volume keys would probably work but I haven't tried this yet as I don't have one.
The main reason I wanted to go with a usb interface is because I didn't want to solder to the rpi or amp directly, and this way I can expand the controls should I want to add other functions.
I followed this guide https://blog.prusaprinters.org/3d-print-an-oversized-media-control-volume-knob-arduino-basics/ which uses code developed by Nico-hood
I haven't managed to get mute working yet, not sure what keyboard command controls this?
I also found out the hard way that each time you want to plug in the keyboard you need to reboot the rpi/amp with keyboard attached before booting.
Interested to hear if someone else has tried something similar and if there are more commands that could be added?