I'm not sure about Jack White but Lennon and McCartney listened to a lot of music and worked out why it was good. They then nicked the best bits and disguised them so people couldn't hear the source.
Listening to music helps you identify the structure, verse, chorus, verse, chorus, bridge/middle 8, chorus or verse, verse, verse, verse, or putting a pre-chorus before the chorus.
You get to hear what melody lines work and what chords go well together.
Alternatively you could study the rules of music and employ them to write your songs. For example, what chords would I use in the key of G and then use them to write the harmony and melody.
You could mix them up, but the final judge is does my song sound like I've copied another tune, and if not, does it sound good.
Hope this helps, if not and you have some more questions just ask.
Keith