Creating and probing nanostructures with X-ray lasers