It would have to be either animations or specific meshes that include the bone linking.
In the case of skeletal meshes the and models:
Just because you delete a bone from the mesh, doesn’t mean that the vertex group associated to the bone is also deleted.
This could possibly be why some bones are still present.