Most modern digital pianos have a midi connection, which can be used with any midi compatible device and most Digital Audio workstations. Using your digital piano through your DAW is a fantastic way to make great use of a quality digital piano. Playing Virtual instruments through a Digital Virtual instruments have gotten so advanced, but there is something special about recording through an original equipment vintage synthesizer.
Some artists prefer using original equipment synthesizers from the 80s and 90s. This is still a valid option, even with the use of DAWs. Before Digital Audio Workstations were a popular format for recording piano through virtual instruments, recording directly from the keyboard / vintage synthesizer on a track was the best way to do it.