If you only want to machine down to the shelf level then that is easy enough, do what warrenb suggests and set the botton height to the top surface of the shelf.
If you want to go full depth then the bad news is that it can`t be done, to get the full shape with the sharp corners it would need to be done on a "wire" cutting machine.
Zip file of Fusion f3d file attached.
Hope that "helps"
Stay Safe
Regards
Rob