There is no magic here. In very simple terms: it is an ISO speed when the speed test is conducted according to the ISO standards, and it is an exposure index (EI) when it satisfies your personal workflow. For example, an ISO 100 film (box speed) may be exposed as EI 64 to create the desired shadow densities. Then you simply say: "I rate this ISO 100 film as EI 64".
Strictly speaking, we should say ISO 100/21° by the way, because the ISO speed is a combination of the ASA speed (100) and the DIN speed (21°). Consequently, ISO 100 is not quite correct. It should be ASA 100 in this case, but dropping the DIN speed from ISO is a common simplification.