Print `DOCTYPE` when serializing.

Simply appending the `DOCTYPE`. Serialization is going to be
reconsidered when we implement streaming serialization.

Closes #84.