Remote/git Packages as Template

Hello,
is it possible to use remote/git packages as a template, so that you can customize variables in the template e.g. via substitution. So that the template can be used multiple times?

Since the following configuration unfortunately does not work, it does not seem to work as with the local !include via vars:.
Is there a solution for this requirement?

# Remote template configuration snippet
packages:
  pm1: #Remote template XY, config 1
    url: https://github.com/...
    ref: main # optional
    files: 
      - base.yaml
    vars:
      modbus_id: modbus_controller_1
      id: mbId_1
      name: mbName_1

  pm2: #Remote template XY, config 2
    url: https://github.com/...
    ref: main # optional
    files: 
      - base.yaml
    vars:
      modbus_id: modbus_controller_2
      id: mbId_2
      name: mbName_2
#Remote template XY
sensor:
  - platform: modbus_controller
    modbus_controller_id: ${modbus_id}
    id: ${id}_system_P
    name: "${name}-P"
    address: 0x0034
    register_type: read
    value_type: FP32
    accuracy_decimals: 3
    unit_of_measurement: "W"
    device_class: "power"
    state_class: "measurement"