If you will encounter this issue, then most likely it was during the installation of DirectX, or other runtime redistributable libraries, but in some circumstances this can also occur while installing the game. This is either caused by lack of administrator privileges in order to install the game, or your security software blocking the setup.
Please firstly add the blocked software (game setup, or redistributable library) to your security software exceptions list/whitelist. Simply disabling firewall or AV software could not be enough, since some of these software are running still in background or in services list.
Next right-click on the software (game setup, or redistributable library) and select "Run as administrator".