Hi, InvoicePlane uses mPDF to generate the PDF file of the invoices (see: Using Templates - InvoicePlane Wiki). This templates are open to customization, as you can understand from the following page: Customize Templates - InvoicePlane Wiki.
To achieve what you are trying to do, a quick research (did not test it) suggests you should use the sethtmlpagefooter
tag (sethtmlpagefooter – HTML control tags – mPDF Manual) as shown here: php - Can i set a specific footer for the last page of MPDF? - Stack Overflow.