Sampling a piano (or any instrument) is very possible but not necessarily very easy. First you need to record the device. For best results every 3rd or so note. The notes need to be recorded at the correct levels and for the correct length for each note. Then you might need another set for a note hit hard and another for a note played softly. Once you have all the notes you then need to create an SFZ or similar type file to play them and a player for the SFZ.
It is a lot easier to use samples professionally done. Having said that it is also good fun to have your own instrument sampled. Years ago I spent considerable time sampling my old Telecaster and actually used it to substitute a bit I could not get right in a song I recorded but I would probably not go down that path again. You may enjoy sampling however.
Tony
Totally agree!
I good instrument will have hundreds (thousands) of samples for multiple velocity layers, round robins, pedal dynamics etc,... TBH, there are a number of excellent free MIDI pianos available online. A quick Google search for "Free piano VST" will get you started.