The list logic does not function properly when selecting multiple instances of the same item.

Your situation is similar to that of a shopping cart. In this case, you may need to create a database table to manage the operation, including columns for “item” and “quantity.” Alternatively, if you are comfortable using JavaScript, you can store the state in JSON format and utilize a toolbox plugin to handle it.