At what point should side-quests (memories/reflections of strength) be undertaken?

Reflections of Strength are completely separate from the main game and have no impact on it - there's no point at which they "should" be done except when you feel like it. They were added pretty late in the game's life cycle as a way for players to just fight the Bosses (including some harder versions) without going through yet another full NG cycle. You can see them as post-game content.

As for the rest, the best advice I can give you is to go back to a previous area and see if there's another path when you get stuck. Sekiro is quite a bit less open than, say Dark Souls 1 for instance, as there are several "chapters" in the story that are unlocked once certain bosses are beaten. The Hirata memory is the only "special" area of its kind, although you can later unlock an "expanded" version of it under some circumstances (not spoiling it here, but it's easy to look it up as it's related to one of the game's endings) Generally I'd recommend doing it after Gyoubu, but if you're finding Lady Butterfly too difficult there's no shame in going back to Ashina a bit and revisiting Hirata later.