I gave a quick look at your query.
You do not use $ in the query part. You should replace
with
"productIdealConsumption.productId":2895
See https://docs.mongodb.com/manual/reference/operator/update/positional/ for examples. You might need to use https://docs.mongodb.com/manual/reference/operator/update/positional-all/ if more than one productIdealConsumption item refers to the same productId within the same top level document. This is not the case in the sample document you supplied but you should be aware.
Your problem is the same as Changing value in nested array from a scalar to an arry.
What is unresolved is how to get the positional value, productIdealConsumption.$.qty in your case. As mentioned in the other thread $map is worth investigating.
Another avenue would be to $unwind, update the unwinded documents, then $group back all documents and use $out or $merge.