[core-api] Make ModuleData and ModuleInstallation Serializable

  * Some backends are still breaking the contract and require ValueType
    classes to be Serializable