Consider the interval $[0,1]$ in $\mathbb{R}.$ Let $\mathcal{B}$ be a subspace topology of $[0,1],$ that is, collection of all sets of the form $[0,1]\cap U$ where $U$ is open in $\mathbb{R}.$ Note that $U = (a,b)$ for some $a<b,$ possibly infinite.
Now, if we add $\{0\}$ into $\mathcal{B}$ and denote the new topology as $\mathcal{B}_0,$ then $\{0\}$ is open in $[0,1]$ with respect to $\mathcal{B}_0,$
Question: Is $[0,1]$ compact in the new topology $\mathcal{B}_0$?
Recall that to show that $[0,1]$ is compact, we need to show that every open covering of $[0,1]$ has a finite subcover.
I think $[0,1]$ is not compact in $\mathcal{B}_0$ because of the newly added open set $\{0\}.$ Consider the covering $$\bigg\{ \{0\}\cup (\frac{1}{n},1]: n\in\mathbb{N} \bigg\}.$$ It is an open covering without finite subcover. Therefore, $[0,1]$ is not compact in $\mathcal{B}_0.$
Is my attempt correct?
I assume that adding $0$ into $\mathcal{B}$ means taking the topology generated by $\mathcal{B} \cup \{0\}$. In any case, $\{0\}$ is open for $\mathcal{B}_0$. Now, since
$$ [0,1] = \{0\} \ \cup \ (0,1] $$
and $(0,1]$ is not compact for the original topology $\mathcal{B}$, there exists a covering $(U_i)_{i \in I}$ of $(0,1]$ by open sets in $\mathcal{B}$ (and hence in $\mathcal{B}_0$) with no finite subcover. Therefore, $\{0\} \ \cup (U_i)_{i \in I}$ covers $[0,1]$ and no finite subcover can be extracted. That is to say, your attempt is correct: you have even identified such a cover for $(0,1]$.