Why do you want to convert *.stl into *.dicom ? What is the application ? could you elaborate on that. *.stl is a cloud of points, but *.dicom format is for 2D images.
If you need to convert *.stl format to *.dicom, you could use Slicer software. Slicer is an open source popular software for visualization and manipulation medical images. It contain different modules for different application.