When I create the MSI, the bdtf.proj file does not have the value for IncludeVirtualDirectories as it comes from InstallWizard.xml.
So, it doesn't not copy the files required for creting the VDIR. When I check the checkbox to choose the installing VDIRs in the deployment, it doesn't find the required files.

So, if I set <IncludeVirtualDirectories>True</IncludeVirtualDirectories> in the btdf.proj, then the files get's copied. But then the variable value from installwizard.xml becomes useless.

Should I create the CustomRedist section to copy the folders explicitly and then use the variable value from installwizrd.xml to apply it?

As long as you are OK with having the virtual directory deployment happen during Visual Studio deployments, then leave <IncludeVirtualDirectories>True</IncludeVirtualDirectories> in your .btdfproj but do one of two things:

1) Move <IncludeVirtualDirectories>True</IncludeVirtualDirectories> into the two PropertyGroup's that include Condition="'$(Configuration)' == 'Debug'" and Condition="'$(Configuration)' == 'Release'". Those are used only for
Visual Studio deployments and MSI generation, so the property will not be set for server deployments.

OR 2) Change <IncludeVirtualDirectories>True</IncludeVirtualDirectories> to <IncludeVirtualDirectories Condition="'$(IncludeVirtualDirectories)' == ''">True</IncludeVirtualDirectories> which will cause the value to be used
only when no value has already been set -- and it will already be set by the install wizard.