In audio, the audio waveform that the instrument produces is captured directly. It is a direct representation of the sound the instrument actually makes over time. Effects can be added of course, but the notes themselves can’t actually be changed. Midi however, is typically generated by a keyboard, a midi controller, or directly into the computer. In a Digital Audio Workstation, midi contains information about which keys are being pressed. This is why recording using midi can be advantageous. If there is a mistake, you can simply drag the note to the right place without having to record again.
