You can't set the name attribute on the net. You'll need to set the net attribute on the path.
netId = dbMakeNet(geGetEditCellView() "newname")
The above command will create the net in the cellview if it does not exist. Otherwise it will return the net id for the net named "newname". Then you assign this net to the path:
path~>net = netId
You can get all the rod objects in a cell by using: rodGetNamedShapes rather than looping through all the shapes in the cell. Although this may be a nit-picking detail, cv is the typical convention for the "cellview id" (cv = geGetEditCellView()). You code could be confusing to someone debugging it by using cv for the selected set.