The capsule goes in but the cube doesn't, I want the capsule to get blocked as the cube

It might be because you box collision is parent to everything else.