Mongo Playground

Configuration

[{name:"algebra",quantity:25},{name:"math",quantity:10}]

Query

db.collection.update({},[{"$set":{"available_quantity":"$quantity"}}],{multi:true})

Result