White dwarfs with strong magnetic fields ($>$1MG) make up only about 10 per cent of the white dwarf population. A further few per cent have fields in the 10-1000 kG range (e.g.Liebert et al. 2003). So it is not clear that the Sun will end up as a "magnetic white dwarf" at all.
The production of magnetic white dwarfs is thought to arise via at least two pathways (e.g. see Wickramasinghe & Ferrario 2005 and the introduction in Dobbie et al. 2013). It is unclear which is dominant
Flux conservation from progenitor stars with abnormally strong magnetic fields. These are the so-called Ap/Bp stars that have fields of 10-100 kG (e.g. Wickramasinghe & Ferrario 2000). The decay time of these "fossil fields" is longer than the stellar lifetime. As the white dwarf radius is a factor of $\sim 100$ less, then flux conservation gives them much stronger B-fields. This might explain why magnetic white dwarfs have (on average) higher masses than non-magnetic white dwarfs - because Ap/Bp progenitors should produce higher-than-average-mass white dwarfs. However, there are some lower mass magnetic WDs and it seems unlikely that the are enough Ap/Bp stars to produce all the strongly magnetic WDs.
They arise in close binary systems that go through a common envelope phase - when one of the stars becomes an asymptotic giant branch star and overfills its Roche lobe. This process results in orbital shrinkage, the main sequence or degenerate companion is brought closer and the system usually becomes a semi-detached binary (often a cataclysmic variable) or the two stars merge. A magnetic dynamo produces strong fields during this process, caused by differential rotation in the common envelope. According to Tout et al. (2008), the B-field that is produced can be frozen into the cooling core that will become the white dwarf. This model can explain why magnetic white dwarfs are never(?) seen as close detached companions to main sequence stars - because this is not a normal outcome of the common envelope phase - and why magnetic white dwarfs are more common as part of cataclysmic variable binaries. It also claims to account for the fact that weak field isolated magnetic white dwarfs are rare. In Tout's theory the isolated magnetic white dwarfs are the results of mergers within the common envelope and these objects should end up with the strongest magnetic fields.
In either of these scenarios, the Sun will not end up as a (strong) magnetic white dwarf. The average solar magnetic field of 1 Gauss, combined with flux conservation could at most produced a white dwarf with a field of $\sim 10$kG. However, it is not clear to me whether this is the whole story. It seems that it is difficult to pin down what the magnetic field is in the solar radiative zone; the field referred to above arises in the tachocline between the convective envelope and radiative core. Some authors suggest that a stronger field could exist in ther radiative zone - a fossil field - and that it would have a very long lifetime - e.g. Friedland & Gruzinov 2004. On the other hand, I don't see how any fossil field could survive the period on the pre main sequence when the Sun was fully convective?