Army History magazine (D 114.20:78) has a wonderful article by Thomas J. Ward, Jr.
When African-American Union soldiers were captured in the south the Confederacy had no idea what to do with them. The one thing they were clear on was that they couldn't treat them as Prisoners of War.
Some were summarily executed. Some were judged to be slaves and returned to their masters. Some were made to work for the Confederate army at the front lines (until Union General Benjamin Butler put white Confederate prisoners in the same position.)
Some free blacks were turned over to civilian courts to be tried but this proved an embaressment when the court ruled that it had no jurisdiction over crimes committed by men acting as soldiers.
Later in the war some of them were treated as POWs but the Confederacy refused to swap them for southern prisoners - which would imply that white and black were equal.