Here are a few places I loved:
York:
York Minster: This an incredibly beautiful cathedral. They have free guided tours are available that are included with your admission price, so I would try and take advantage of that if possible. https://yorkminster.org/free-guided-tours/
Edinburgh:
Stirling Castle (and town): As Jules mentioned, making a day trip to Stirling would be perfect. The town of Stirling is a gem, with many historical sites, like Church of the Holy Rude, and Stirling Castle is just wonderful. It's an easy 40 minute train ride from Edinburgh to Stirling, and the town itself is very walkable. Keep in mind that the castle is on a hill overlooking the city period. You can get a taxi up there or a bus, or walk if you're so inclined. I actually walked and I enjoyed the walk and when I got to the top, seeing the beautiful view from the castle over the countryside was incredible. The castle itself offers free guided tours beginning at 10 am every hour on the hour. Take one of those if you can. They're well worth the time. Our guide was fantastic; very funny and very knowledgeable.
Also, Stirling has Darnley Coffee House, which is located in the house that Lord Darnley, who was married to Mary Queen of Scots, lived in. I highly recommend this place. When I was there, the room was filled with locals, and we all started talking. They were asking me lots of questions about the states and about my travels, and why I was traveling alone and so on. But they said they all come here a lot because they like it. The food was very good, and the building itself is pretty cool.
Edinburgh Castle: I did not really enjoy my visit here. I had bought a Historic Scotland pass so booked a time online but did not have to pay anything extra, which I’m happy about. I think that paying the steep price would have annoyed me. The sheer size of it and grandeur was impressive, I’ll admit, but the inside just wasn’t that appealing. I think I would have been happy just seeing the outside. I'm not sure why, although part of it is probably because it's mostly about the military, which I'm just not that interested in. If you are, you might think differently. And of course, many people love the castle.
St. Giles Cathedral: This was beautiful on the outside and inside, and had some interesting history. I especially enjoyed seeing the John Knox statue, but even more finding out that his burial site is outside in the car park below number 23.
Calton Hill: This is a hill that you can walk up and look out over the city. There are some steep climbs, but the end result is worth it and you get a glorious view.
Greyfriars Cemetery: This was one of my favorite places and not just because of Harry Potter. It has a very macabre vibe to it, so going in the dusk of the evening is best. I first saw the memorial and grave of Greyfriars Bobby, the loyal little dog who guarded his master’s grave for so long. Then I tracked down the gravestone of Thomas Riddell, whose name was the inspiration for J.K. Rowling’s notorious villain. If you’re looking for it, just put the name in Google maps and it will show you the way. It was also fun looking through the black gates to see the school that inspired Hogwarts.
National Museum of Scotland: I loved this museum! There were so many interesting and eclectic items here that I could have spent days instead of hours. Dolly the cloned sheet is here, as are more of the Lewis chess pieces I saw at Lews Castle. And much much more! I was there when several school trips happened to be visiting but the kids loved it and were so excited about all the exhibits.