Not able to update one of the key value by using JSON_MODIFY function in SQL Server
Your 'counter' properties are in an object within an array, so your JSON path in JSON_MODIFY isn't correct. You need to reference the index of the item in the array to correctly update the value:

UPDATE test01
set json_data = JSON_MODIFY(json_data,'$[0].counter2',2000)
where test01_id =10


If you had additional objects in the array with different counter 1/2/3 values, then you would need to reference them with their correct index, i.e. [1], [2] and so on. You can see a working example of this here.