piano with arduino uno

So you're trying to push a whole bunch of buttons and get multiple frequencies right? That's 'polyphony'.

Maybe you can just have the arduino detecting the state of each key using a separate digital input (with debouncing circuitry to avoid bounce issues, if necessary) for each key.

1 key per digital input.

But then, later on - you might need to think about 'after touch', which is really basically extra features - like 'velocity sensing' - like.... how fast you push down on the key determines how loud a sound is played. But that would involve keys having velocity sensors.