Apparatus and method for printing two-dimensional barcode and articles incorporating such barcode