You can do this in ImageJ or it's new version Fiji. It reads DICOM images and has a number of tools for creating binary masks. You should go through the documentation section on the Fiji website on how to segment that. Fiji also includes the Weka machine learning engine which can be trained to segment images.