Finally I have installed the mod_plugin (i.e. Activity Modules Plugin) successfully.
It accepts any Moodle version greater that Moodle 3.
new plugin name - test
old plugin name - miv
Now two steps need to follow:
STEP1: Go to plugin/lang/miv.php - Replace file name with new name i.e. test
STEP2: Open this file i.e. lang/test.php
Replace in entire project:
mod_miv with mod_test
miv with test
STEP3: Replace functionality replaces only in code and not file name. So now go to each folder of the plugin replace filename whereever miv with test
STEP4: You will write your code in view.php