In light of the race imagery encountered in Romans 9:30–33,1 it is likely that the apostle Paul uses τέλος in Romans 10:4 in the sense of the finish line and/or prize in a race.2

In the race, the Israelites ran after (διώκω)3 the goal or prize: righteousness (δικαιοσύνη). The Gentiles are those who neither willed nor ran.4 Despite this, the Gentiles attained (καταλαμβάνω)5 the prize: righteousness.
The apostle Paul explains that the Israelites ran after the prize (righteousness) by doing the works of the Law.6 By doing so, they tried to obtain their own righteousness.7 Since the righteousness of the Law demands perfect obedience, the Israelites did not attain the prize.
On the other hand, the Gentiles believed in Jesus Christ, the righteous one,8 and by doing so, they attained the prize of righteousness—“the righteousness of God which is by the faith of Jesus Christ to all and upon all those who believe.”9
Douglas J. Moo wrote,10
Perhaps the best way to answer this question is to go back to the race imagery that Paul has been using in this context. We might picture the law as the race itself. Christ is the finish line. As Israel runs the race of the law, they should always, of course, have their eyes fixed on the finish line. Instead, Paul has been suggesting, Israel concentrated so exclusively on the race that they forgot about the finish line. With the coming of Christ, that finish line has been reached, but Israel does not recognize it.
In Romans 10:4, it is written,
4 For the finish line and prize of the Law is Christ for righteousness to all who believe.
Δʹ τέλος γὰρ νόμου Χριστὸς εἰς δικαιοσύνην παντὶ τῷ πιστεύοντι. NA28, ©2012
For those who do not believe (i.e., have faith) in Christ, he is to them a stumbling-block which prevents them from finishing the race and attaining the prize of righteousness, the righteousness from faith.
Footnotes
1 LSJ, p. 1773, τέλος, III., 2., b.
2 On the race imagery, see Schreiner, p. 121:
“Racing imagery is employed in Romans 9:30–33.”
Meyer, p. 391:
On the figurative διώκειν, borrowed from the running for the prize in the racecourse, as also on the correlate καταλαμβάνειν, comp. Philippians 3:12-14; 1 Corinthians 9:24; 1 Timothy 6:11-12; Sirach 11:10; Sirach 27:8.
3 BDAG, p. 254, διώκω, 1.
to move rapidly and decisively toward an objective, hasten, run, press on (Il. 23, 344; Aeschyl., Sept. 91; X., An. 6, 5, 25; Hg 1:9; Is 13:14; Philo, Virt. 30 διώκουσι καὶ ἐπιτρέχουσιν) κατὰ σκοπόν toward the goal Phil 3:14; cp. vs. 12 (on the combination w. καταλαμβάνω cp. Hdt. 9, 58, 4; Lucian, Herm. 77; Sir 11:10; La 1:3 v.l.).
4 Rom. 9:16
5 BDAG, p. 519, 1.
to make someth. one’s own, win, attain...abs. of the winning of a prize 1 Cor 9:24.
6 Rom. 9:32
7 Rom. 10:3
8 Acts 7:52
9 Rom. 3:22
10 Moo, p. 215
References
Liddell, Henry George; Scott, Robert; et al. A Greek-English Lexicon. 9th ed. Oxford: Clarendon, 1940.
Meyer, Heinrich August Wilhelm. Critical and Exegetical Handbook to the Epistle to the Romans. Trans. Moore, John C.; Johnson, Edwin. Ed. Dickson, William P. New York: Funk, 1884.
Moo, Douglas J. Encountering the Book of Romans: A Theological Survey. 2nd ed. Ada: Baker Academic, 2014.
Schreiner, Thomas R. Paul, Apostle of God’s Glory in Christ: A Pauline Theology. Downers Grove: InterVarsity Press, 2001.