I can't hold more than a few keys at once while playing osu!mania.
This is due to an issue that most keyboards suffer from called "ghosting", where certain key combinations cannot be pressed together. Many newer keyboards can allow up to 6 keys to be held down at once, mostly in random combinations.
There are applications available that will help you determine the maximum number of concurrent keypresses that your keyboard can handle. Check this link for one!
Keep in mind that most of the ranked osu!mania maps are designed to prevent the influence of ghosting in most cases, by only allowing up to 6 simultaneous key presses at once.
If you cannot reliably play osu!mania due to ghosting issues, then your only recourse is to purchase a keyboard which is capable of handling more key presses at once. Ideally a keyboard with "n-key rollover" or "NKRO".