A 1042-S isn’t a form that you fill in yourself - the name is indeed a little misleading. It should already be filled in before it’s sent to you.
On it, you should see a box (#4) that says “Federal income tax withheld” - this is the amount of money that was withheld from your earnings and sent to the IRS. In other words, this document is your proof that you paid taxes to the IRS.
Depending on your country’s tax laws and treaties with the United States, you may be able to use this form to receive a refund on some of those taxes. This is definitely something to discuss with an accountant if it’s important to you.
There’s some more information on the bottom half of this page: https://help.author.envato.com/hc/en-us/articles/360000471123-Tax-Forms-1099-and-1042-FAQs