All you need to do is to add a data-matomo-form attribute to any element that contains all your form fields and a data-piwik-name="..." attribute to specify the name of your form. Learn more about this in the Form Analytics setup guide.