is this happening because of the rig or something else? and how can i fix
It's your Weight Painting.
Select the mesh, key Ctrl + Tab to enter Weight Painting mode, and key T to toggle open/close the Toolshelf. Go to the 3D Viewport > Toolshelf > Brush > Weight: value and enter 1. Drag the brush over the problem spots. They should change from blue to red and rejoin (jump to) the rest of the mesh (foot).