Some instruments lend themselves to MIDI, typically those instruments that have clean predictable sound with a predictable starting point. It's far easier to emulate a piano than a wailing blues harmonica which has unpredictable runs, mouth noises and a good deal of spit.
When you strike a piano key there is little you can do after to change the note. If you strike it harder the wave form changes in ways that are only loosely to do with the simple math of increasing amplitude, but are also to do with the size of the case, the length and type of the string (s) and a whole host variables.
Each piano string also creates sympathetic resonances. Other strings that have not been struck, but share simple harmonic relations actually sound 'in sympathy'.
A good virtual piano will have several different samples for each note if its sample based, or it will have an algorithm for each note.

Emulating a violin is harder, the bow can strike the string in over fifty differemt ways [called articulations], then as the sound continues, various amounts of vibrato can be added, humanising the sound. Also the angle and pressure of the bow can be varied.

If you are a drummer you will also know that every time a cymbal is struck it creates a different noise - using the same sample to say tap out a triplet series will sound wooden and lifeless. This is called the 'machine gun effect' and IMO is even present when the velocity is altered.

Notes Norton has already explained the timing issues, randomisation does not realy sub for humanisation, each phrase may purposly bend the rules of metronome timing, though perhaps without the player realising. A good player does not randomise but may 'play' with the timing. Billy Holiday comes to mind as someone who instinctively slips and slides over timing and sounds fantastic.

Recreating all this in a track is really a challenge if one does it well, for one has to understand exactly what goes on at a subconcioous level in the music, whether it is swing, a latin montuno or a marching band. Frequently simply playing the piece in is the best option, but playing, for example a guitar part in on a keyboard, will not capture the fret noises and muffled notes present in a real guitar .

Real tracks are real people playing real instruments.


Win 11 64, Asus Rog Strix z390 mobo, 64 gig RAM, 8700k