Hello and welcome. Yes you can, but I wouldn't. Why? If you have any type of current, as you should, sweeping over your tank, once an invert or fish swims by and disturbs it from the sand, the current will then sweep it away. Usually behind your rock work or somewhere inside of it. You will either never see it again unless you start tearing down your reef or have to dig it out of your reef. The best thing to do is to secure it to a small/med/lg rock with reef glue, thread, lose rubberband etc until it adheres to the rock on its own. This will take a week to 10 and sometimes longer to happen. That will depend solely upon your tankmaturity, parameters etc. Then you can place it in the sand, but even then I wouldn't do that. Is there a reason why you don't want it attached to any rock or on your reef?
Good luck, good question, and again, welcome.
MUCHO