There's no problem with filling the hole right next to the foundation. That exactly what they do when adding on additions to houses. The "bolts" you see coming out of the existing foundation are just the ends of rebar, steel rods,nails used to strengthenframe the foundation/slab. They are installed before the foundation is poured for pouring. You can cut those pieces off if you want, it won't affect the foundation.