I’m tired now, so, if after reading the following FAQ, you still have questions, I’ll answer them tomorrow, or somebody else may jump in before then.
Basic point: with a smartthings account, you can create a “virtual device” which doesn’t have any reality outside of software, but which your smartthings account will treat something like a real device. It will show up on the device list in your smartthings app, and it can be shared with other platforms like Alexa. And if it’s a virtual contact sensor, there will be a way (the exact method may vary a little) to change it from closed to open and back again using just a smartthings routine. So these are used for a lot of different things, but one of the things they are used for is to trigger Alexa routines (not SmartThings routines).
Here’s the FAQ on that method: