Yes, indeed. Computer programs for doing this have been around for more than 30 years.
But to help your son with his timing, you don't want to record and display audio waveforms, and you don't want to have a computer program transcribe his recorded playing into standard music notation (there are certainly programs that can do this, but this will be of little use to him at this stage, as I will explain below). What you need instead is to record and display his playing on a MIDI piano-roll editor.
The kind of computer program that can do this (among many other functions) is called a Digital Audio Workstation, or DAW. There are myriad programs available for Mac and PC. They are all designed for musicians to record and edit music. They are not specifically designed to help a student analyze whether they are playing in time or not. But they can be used for that purpose.
In this usage scenario you cannot use a real acoustic piano. Rather, you need a digital piano or keyboard which is connected to the computer and the DAW application using the MIDI protocol, with MIDI cables or MIDI-over-USB.
[You need to understand what MIDI data is; in this usage scenario, you are not recording the audio from your son's piano playing. Rather, you are recording the MIDI data generated by your son's fingers depressing and lifting each individual key on the keyboard as he plays. This gives the great advantage of being able to display and analyze each individual note, to a greater degree of accuracy and resolution than is possible by recording audio and looking at the waveforms.]
As a basic assumption, your son needs to be accustomed to practicing with a metronome.
The DAW program running on the PC or Mac records what your son plays on the keyboard (while he listens to and plays according to its metronome click) and then displays each note on a scrolling graph, showing its exact start and stop position against a grid display. The graph and grid is referred to as a piano-roll MIDI editor.
The DAW program can usually display the MIDI data either on the piano-roll grid or as standard music notation (with some limitations). For someone who has bad timing, however, switching to standard music notation created by the program from MIDI data is not going to be helpful, as the music notation faithfully transcribed from the errant performance is going to look like a lot of garbled nonsense.
Piano-roll MIDI editor view of a piano part recorded in Apple GarageBand. The green bars display the exact starting position and ending position of each individual note, against a grid that shows the measures of music and subdivisions of the beats in each measure, according to the metronome.
The same piano notes recorded in GarageBand displayed in standard notation. The only reason the notation looks good in this example is that the notes were played extremely accurately in the first place.
Examples of suitable entry-level Digital Audio Workstation (DAW) programs are:
Most of these programs exist in several different versions: a free version for beginners, an inexpensive version for intermediate users, and an expensive version for professional studio recording. For your purposes, you can get the least expensive version of any of these programs.
Learning to set up and use any of these programs is not intuitive. It requires reading the owners manual that comes with the program, and working through the tutorial examples, or possibly watching a professional tutorial video series or reading a third-party how-to book. When you launch one of these programs for the first time, you will have absolutely no idea how the program works or how to get it to do what you want. So you will have to do some reading and studying.