Texture on an vertex array drawn shape

So I want to recreate minecraft, I have created everything, it does create chunk shape, it draws it, but how I can put corresponding texture.

What I’m thinking at, but I don’t know how to apply is to create an array of texture array for every texture.