It's usually used when directly quoting something that is mis-spelt or grammatically wrong, to indicate that although the original author might be a muppet the person quoting them has picked up on their mistake, e.g. 'The Minister for Education wrote: "It's important for young people to learn how to spell properlie" [sic]'