IRS Form 8843 Statement for Exempt Individuals and Individuals with a Medical Condition, For use by alien individuals only, is used to exclude days of presence in the U.S. for certain individuals. According to the instructions for the form, it would either be mailed to the IRS alone or with Form 1040NR or 1040NR-EZ.
Per IRS Publication 519 U.S. Tax Guide for Aliens, page 6:
Form 8843. If you exclude days of presence in the United States because you fall into any of the following categories, you must file a fully completed Form 8843.
Attach Form 8843 to your 2019 income tax return. If you do not have to file a return, send Form 8843 to the following address. Department of the Treasury Internal Revenue Service Center Austin, TX 73301-0215. You must file Form 8843 by the due date for filing Form 1040-NR or Form 1040-NR-EZ. The due date for filing is discussed in chapter 7.
To enter information for Form 8843: