I have finished the game and I did get those chests, but I honestly cannot recall the exact sequence now.
You may simply need to come back later with the right item. In the meantime, a Spirit Tracks walkthrough is the reliable answer here — the puzzle explanations are clear and will save you a lot of wandering.