Hello, and welcome to Godot Q&A :)
CollisionShape2D (and children) are editor helper nodes, meaning that it does not actually exist at runtime (or didn't), therefore changing it via script does nothing after the Physics body has used it.
The one way I found to work around this was by defining a prototypical shape, saving it it as a .res, preloading it. Then you have to duplicate and scale it at runtime, and call set_shape on your PhysicsBody2D, as such:
var protoshape = preload("res://shape.res");
var shape = protoshape.duplicate();
There may be a simpler way, but I can confirm this works.