Where did you find the record for Lewis in the 16th Mississippi and his discharge for medical reasons in 1862, and in what capacity did he serve? I could not locate.
I am aware however, that many blacks served as cooks and alongside their officers masters. And some did serve in rifleman rolls.
…………………
“Blacks did not serve in the Confederate Army as combat troops. Blacks were not merely not recruited; service was actively forbidden by the Confederacy for the majority of its existence. Enslaved blacks were sometimes used for camp labor, however.”
https://www.bing.com/search?q=blacks+in+the+confederate+army&FORM=QSRE1