Improvisation is creating music on the spot. It is not a reproduction of a prepared piece. It does, however, consists of reproducing practiced patterns but focuses on the act of creation, playing what is required in that moment.
Many aspects of musical playing are active in improvisation. The most relevant ones might be: