I worked for the same employer and lived in Maryland for all of 2019. In 2020 I moved to West Virginia but still worked in Maryland. I have never worked in West Virginia or had any income from West Virginia but my W2 says I made money in both states!
Your W-2 does not say you made money in both states. It only says you had income tax withheld for both states. You employer did it correctly.
MD & WV are "reciprocal states". Once you moved to WV, you employer shoulda stopped withholding MD tax and started withholding WV tax. You are now only taxed, on wages/salary, by WV, not MD. Staring in 2021, you will not longer file a MD tax return.
for MD, if you haven't done so already you should submit form MW507 to your employer so only WV income taxes are withheld. some employers may do the correct withholding automatically without the form
If you moved to WV in 2019, your employer should not have withheld ANY MD taxes for 2020.
If you haven't already done so, submit MD Form MW507 (as @Mike9241 stated) to your MD employer ASAP, checking the West Virginia box on Line 4.
For your 2020 tax returns, enter your W-2 exactly as is.
For 2020, file a non-resident 2020 tax return to MD, showing zero MD income. This will cause MD to refund the incorrectly withheld MD taxes.
File a 2020 resident tax return to WV. All your 2020 income is taxable by your 2020 home state of WV.