As I see it, there are two distinct questions: (1) Can you publish without putting your PhD supervisor on a paper to which she/he has not(!) contributed? (2) Can you include such a paper as part of your thesis?
1. Can you publish without putting your PhD supervisor on a paper? Basically all scientific journals have publishing guidelines stating that only those people should be included in the list of authors who have made important contributions to the paper. So, if in your case your supervisor did not contribute to that specific paper, then it is not even allowed to put him/her on the paper. Naming people as authors who have not contributed to the work is considered scientific misconduct. Note, that some journal guidelines even specifically state, that being the head of the division, department or institute, or providing funding for the research is not sufficient for earning authorship. There must be an intellectual contribution. If, on the other hand, your supervisor has made an intellectual contribution to the paper, then it would be misconduct not to include him/her on the author list (or at least offer them to include them).
In order to publish scientific work in a journal you do not need an academic title: you can publish as distinguished professor, but also as student or even as layperson that has never set foot into a University or institution of higher education. If you read through journal guidelines you might also notice the general absence of words like ‘student’, ‘supervisor’ or ‘professor’. The only distinction that is technically made is between corresponding author and co-authors. Here again, a supervisor has no privileges or a right to be the corresponding author only because of his/her rank/function. The idea of academia is that your contribution is evaluated based on the content only and not based on your gender, nationality, age or rank. So, even as a student or as a lay person you have the right and the opportunity to publish on your own account–as long as this work is yours. (It’s not too frequent, but it does happen.)
Has your supervisor made an intellectual contribution to the paper? This might be a question that might be more difficult to answer and where you and your supervisor might disagree. If your supervisor read and commented on your manuscript, this counts as a contribution; but also if he/she just discussed the ideas with you informally or within seminars, this can be considered a contribution. Arguably, even suggesting the topic of the thesis can be seen as contribution, though here the question arises how detailed this suggestion is. If the suggestion is of the kind “you might work on quantum mechanics”, this does obviously not give your supervisor the right to be on all papers you will ever publish on quantum mechanics. If, on the other hand she says “Hey, look at the work of XY and their results YZ, which are rather interesting because they imply that XX and therefore it would be interesting to investigate what happens when ...”, then this idea/plan might be a substantial intellectual contribution. So it is really the question of how much did the supervisor contribute. Who can decide that? I do not agree with the notion that only the supervisor can decide this because of his/her experience. If you have never discussed the content of this specific work with them, then you will know that and then it is correct not to include them. (Note, however, that this is the best way to make new enemies for the rest of your life.) Legally, this is a question of intellectual property. Only few disputes between academic authors go that far that they are brought to court, but if they would, it is by no means said that judges would agree that a teaching relationship gives supervisors automatically rights on their PhD students intellectual output.
To sum this up, I cite from the guidelines of the International Commettee of Medical Journal Editors: "Examples of activities that alone (without other contributions) do not qualify a contributor for authorship are acquisition of funding; general supervision of a research group or general administrative support; and writing assistance, technical editing, language editing, and proofreading."
2. Can you include such a paper as part of your thesis? This is a different question from publishing and depends basically on the policy of your University and the ruling of your thesis committee. The official University regulations are usually rather vague on such things. They sometimes regulate what kind of clothes you have to wear for the exam or graduation ceremony and they generally say that you have to hand in a written thesis that must be examined etc.. but they usually don’t say anything about shared authorship in publications. The supervision agreements I have seen, so far, usually have some statements that a requirement for submitting your thesis is that a number X of papers have to be submitted to or accepted by peer reviewed indexed journals, etc.., but I have never seen agreements that explicitly state that your supervisor has to be on all those papers. So, whether you can add your paper to your thesis depends on the judgement of your thesis committee. If your supervisor is part of the committee, that might be a problem.
At this point it is worth to mention that just 2-3 decades years ago the publishing culture was rather different with many papers being single-author papers –specifically papers stemming from a PhD thesis. John Nash published his thesis outcome as a single author paper (in PNAS) so did Alan Turing, John Krebs and many others. (Ok those were more than 30 years ago, but there are also enough more recent examples). Since then, publishing practice has changed, but most examination regulations of Universities haven’t kept up with that change and do not consider the issue of co-authorship at all. But they usually do consider the PhD candidate to be a rather independent and intellectually mature subject, and they do regard the thesis as a piece of work that should be the sole intellectual work of the candidate. When you hand in your thesis, you usually have to sign some sort of declaration that you wrote the thesis all yourself. If you are handing in a paper-thesis (where the main part consists of published or to-be-published journal articles) and if these articles are multi-author articles, then you are—strictly speaking—contradicting yourself (because in the author contribution statements of those articles you will usually read something like “XY did this, YZ did this and all authors wrote the paper together”). So, the old idea of a thesis as an entirely independent piece of work done by the candidate alone, as it still lingers around in the examination regulations of most Universities, does not fit together with the highly collaborative way science is done today. As current practice and the official rules and regulations do not fit together anymore, this is also legally a grey area.
Publication have a very central role in the evaluation of academic researchers and, as a consequence, many of the most bitter feuds that are fought in academia originated from disagreement about authorship of formerly collaborating scientists. Many people will have strong feelings about this issue, because they have already been in one of the two situations: where they have unjustly been left out from an author list or where they were pressured in putting people on one of their papers that did not contribute anything useful or anything at all. I, too, have experienced both.