I'm late, but I think the answer can be given in a simpler fashion.
A principal bundle is in particular a fibre bundle, but there exists no residual choice of whatwith the extra restriction that the fibre should be — it musthas to be a group $G$ by definition. To me, the most direct way of recovering the choice of aagain relaxing to an arbitrary fibre $F$ in $P(M,G)$ is to first enlarge $P$ to be a trivial fibre bundle (with fibres $F$) like $P\times F$ and then dividing out the unwanted oldgroupy fibres $G$: $$E:=(P\times F)/G\quad\text{meaning we identify}\quad (u,f)\sim(ug,g^{-1}.f).$$ This is like if you want $5$ to be $7$, you boldly write $$7=(5\times 7)/5.\qquad\text{(sorry)}$$