What happens to $\operatorname{Var}\left(\varepsilon_{i} \mid x_{i}\right)$ if there is heteroscedasticity?

What happens to $\operatorname{Var}\left(\varepsilon_{i} \mid x_{i}\right)$ if there is heteroscedasticity? Also, why is $\operatorname{Var}\left(\varepsilon_{i} \mid x_{i}\right)=\sigma^{2} ?$


Heteroscedasticity means the variance is not a constant. Hence you can't write that it is equal to a constant.

In the setting of homoskedasticity, then the variance is the same, hence we can just use a contant $\sigma^2$ to denote the variance regardless of the value of $x$.