Hello @Rakesh S ,
The IoT Hub supports two kinds of devices, 'direct internet-connected' devices and Azure IoT Edge devices.
The first group of 'physical' devices supports the concept of 'logical' modules. Each module has its own identity and twin:
This is useful eg. if a device is split up into different individual parts (perhaps from multiple vendors?) but working together as one.
For example, in the past, I have seen how the internal hardware of a TV set was produced by different vendors and all parts were interconnected by the smart tv software. Here, this device/module option could be useful.
The second group is the group of Edge devices, this is what you want to manipulate.
An edge device also supports the concept of modules, each with its own twin but not with a separate identity.
You manipulate an edge device using a deployment manifest. This is a JSON text which describes which modules you want to deploy, what the registry location of these (docker container) modules are, and how the internal routing is set (next to configuration, properties etc.).
For this, a separate REST call is available:
POST https://fully-qualified-iothubname.azure-devices.net/devices/{id}/applyConfigurationContent?api-version=2020-05-31-preview
How to use this REST call is described here.