How to combine Render Layers correctly
Option 01 - for Cube Render Layer mark Floor Render Layer as Mask Layer




Option 02 - use Z-Combine node to merge them together




Notes: It is good to understand what happened in 2.8x versions ...

Render Layers are almost the same concept
Layers are in 2.8 represented by Collections. Now you are not selecting Collections to be rendered, but you mark collections you want to participate only indirectly - objects are not rendered directly, only indirectly by their shadow or light bounce
Mask Layers are the same concept in therm of just activating collection in outliner