I believe it is not correct for your employer to withhold IL taxes on your wages. In PUB-130 page 4, "When must I withhold Illinois Income Tax
from my employee’s compensation?", it says,
You must withhold Illinois Income Tax when you withhold federal income
tax from compensation you paid in Illinois. Compensation is paid in
Illinois when the employee’s services are “localized” in Illinois.
Your services are not localized in Illinois because you did not perform your services in Illinois. On that page, it goes into detail about, "When is compensation paid in Illinois?" But it seems that none of those items apply to you.
- If the employee’s service is localized in Illinois because all of the service is performed in Illinois, then compensation is considered
paid in Illinois and subject to Illinois income tax withholding.
doesn't apply because the service is not performed in Illinois. And
- If the employee is an Illinois resident and
- neither of the rules above apply and
- no other state’s taxes are withheld,
then compensation is considered paid in Illinois and is subject to Illinois
income tax withholding.
also doesn't apply since you are not an Illinois resident.
I believe you would file an Illinois nonresident return, i.e. attach Schedule NR to your IL-1040. On your Schedule NR, you would put federal amounts in column A and all 0 for Illinois amounts in column B. In the Schedule NR instructions for column B, line 5 (wages), it says that you must put the amount that is listed on your W-2 as Illinois wages, and that if it is incorrect you must attach a letter from your employer on company letterhead stating the correct Illinois wages. So I believe you have to either get your company to issue a W-2 with Illinois wages listed as 0, or get your company to write an official letter stating that your Illinois wages is 0, or that you did not perform your services in Illinois.