With the rapid development of precision manufacturing, the optical non-contact three-dimensional measurement method for detecting the morphology of tiny objects has gradually become a hot topic with the advantages of high speed, high precision, large measuring range and high repeatability. When the depth of the microgroove reaches a certain range, the general three-dimensional measurement method cannot be used since the depth of focus is usually not deep enough. In this paper, we proposed a new method of detecting based on the grating projection for detecting phase, which introduced a novel diffractive optical device called Dammann zone plate for measuring three-dimensional shape of tiny objects with an extend of focal length. Dammann grating can produce a finite array of uniform intensity spots in the Fourier transforming plane by modulating the transverse position of the transition points of the binary optical phase. Using this feature, the Dammann zone plate takes advantage of the periodic coding details of the Dammann grating for producing an axial multi-focus system with equal intensity in the focusing system when combined with a focusing lens. This experiment, the depth of focus is greatly extended due to the introduction of Dammann zone plate, which can measure deeper grooves. Therefore, we can collect more three-dimensional information of the tiny object with a CCD camera, and then we can obtain more accurate three-dimensional morphologic profile. This method is simple, accurate and robust for practical applications, so it is highly interesting for detecting deeper grooves of tiny objects.