Some of gltf's children mesh seems can't be "modified"

Hello guys!
Today i tried to modify some gltf model by changing it’s material.

new GLTFLoader().load('./resources/loader/M1A2/scene.gltf',gltf=>{
    gltf.scene.scale.set(0.01,0.01,0.01)
    this.scene.add(gltf.scene)
    gltf.scene.traverse(e=>{
        console.log(e.type)
        if(e.isMesh || e.isSkinnedMesh){
            const parent = e.parent
            parent.remove(e)
            parent.add(new THREE.Mesh(e.geometry,new 
                THREE.MeshLambertMaterial({color:0xFFFF99}) ))
            }
        })
})

But some meshes remain their original material.

original

modified

Please do not modify object hierarchies in traverse operations. It seems you only want to update materials so consider to do this:

if(e.isMesh) {

    e.material = THREE.MeshLambertMaterial({color:0xFFFF99});

}

Thx , it do solve this question.
However , I need to modify object somehow , cause I actually want to do csg which returns me a new mesh

Ah! Never mind my last comment , I just implement this like you said.

const mesh = csg(e)
e.geometry = mesh.geometry