Persons owning lands abutting upon a railroad may construct, at their own expense, crossings under, over, or across the railroad and drains under and across the railroad at places and in ways that do not obstruct or impair the use of the railroad. Before constructing them, the owner of the land shall serve on the nearest station agent of the company a notice, stating in detail the work which the landowner desires to perform, and the company may construct that work; but the crossings and drains may not be opened for the use of the landowner until the landowner pays the reasonable cost of construction. These crossings and drains must be maintained and kept in repair by the railroad company; however, the railroad may require reimbursement from the abutting landowners of its reasonable and accountable maintenance and repair costs when maintenance and repair are initiated by the landowner and agreed to in advance by the railroad company. The railroad company shall ensure, allow, and not prohibit reasonable egress and ingress under, over, and across a crossing except as may be required for maintenance of the crossing or for normal operation of the railroad.